‘*.dbo.CONTENT is not supported’ error when editing a page in SQL Server environment
Platform Notice: Data Center - This article applies to Atlassian products on the Data Center platform.
Note that this knowledge base article was created for the Data Center version of the product. Data Center knowledge base articles for non-Data Center-specific features may also work for Server versions of the product, however they have not been tested. Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.
*Except Fisheye and Crucible
Problem
The symptom for this issue is that pages cannot be either edited or created.
It looks like a synchrony problem, but you cannot find a clue related to Collaborative editing .
It happens only for the SQL Server environment, especially it usually happens in a staging environment just copied from production environment.
You may find “*.dbo.CONTENT' is not supported“ error and HHH000346 SQL error in application log as below.
2023-01-01 10:00:49,999 ERROR [http-nio-8090-exec-1] [engine.jdbc.spi.SqlExceptionHelper] logExceptions Reference to database and/or server name in 'confluence-sqldb_2019-01-01T03-03Z.dbo.CONTENT' is not supported in this version of SQL Server.^M
-- space: 1001 | url: /plugins/editor-loader/editor.action | page: 1000001 | traceId: | userName: abc0001 | referer: https://abc.xyz.com/pages/viewpage.action?pageId=1000001 | action: editor
2023-01-01 10:00:50,000 ERROR [http-nio-8090-exec-1] [org.hibernate.internal.ExceptionMapperStandardImpl] mapManagedFlushFailure HHH000346: Error during managed flush [org.hibernate.exception.SQLGrammarException: could not execute statement]^M
-- space: 1001 | url: /plugins/editor-loader/editor.action | page: 1000001 | traceId: | userName: abc001 | referer: https://abc.xyz.com/pages/viewpage.action?pageId=1000001 | action: editor
Cause
The cause for this problem is due to you may forgot recreating triggers in staging DB, which is copied from production DB.
When using SQL Server, recreating triggers is a necessary step , which is mentioned in Create a staging environment for upgrading Confluence .
Resolution
Run below SQL query to check if there is any trigger pointing to original DB
SELECT table_name = so.name
,trigger_name = st.name
,trigger_text = sc.text
,create_date = st.create_date
FROM sys.triggers st
JOIN sysobjects so ON st.parent_id = so.id
JOIN syscomments sc ON sc.id = st.[object_id];
Drop the triggers found by above query
Recreate the triggers, and point to correct DB.
Enable the triggers