Magnolia to MS SQL 2014 connection
#1 by pmayank1991 on Dec 26, 2016 1:08:16 PM

Hi Team,
I am new to magnolia and I am trying to integrate MS SQL 2014 server with magnolia 5.4 version, I have created Persistance Manager by reffering the documentation present at https://wiki.magnolia-cms.com/display/WIKI/Setting+up+a+Jackrabbit+persistence+manager and it's working fine but still most of the content were stored in my local file system.
I want all my content to be stored in SQL server 2014, I followed all the steps mentioned at https://wiki.magnolia-cms.com/display/WIKI/Database-Only+Repositories+with+JNDI+Datasources but I am getting the following error:
--------------------------------------
INFO info.magnolia.init.MagnoliaServletContextListener 26.12.2016 17:28:29 -- Property sources loaded: [DefaultMagnoliaConfigurationProperties with sources: [SystemPropertySource][ServletContextPropertySource from WEB-INF/config/magnoliaAuthor/magnolia.properties][ServletContextPropertySource from WEB-INF/config/magnoliaAuthor/magnolia.properties][ServletContextPropertySource from WEB-INF/config/default/magnolia.properties][ModulePropertiesSource from modules [core, dam, freemarker-support, lang-el, activation, categorization-support, ce-product-descriptor, imaging-support, resource-loader, rest-client, rest-integration, cache, config, i18n, rest-services, dam-jcr, ehcache, rendering, ui-framework, appswitcher, imaging, resteasy-client, scheduler, templating, ui-mediaeditor, resources, task-management, templating-jsp, ui-admincentral, about-app, cache-app, groovy, inplace-templating, log-tools, mail, messages-app, pages, resources-app, sample-app, security-app, site, ui-contentapp, cache-browser-app, contacts, dam-app, dam-imaging, dam-templating, definitions-app, form, google-sitemap, jcr-browser-app, jcr-tools, mte-imaging, site-app, mte, public-user-registration, forum, mtk, rssaggregator, categorization, commenting, lang-da, lang-ar, lang-cs, lang-de, lang-es, lang-fi, lang-fr, lang-he, lang-hr, lang-hu, lang-id, lang-it, lang-ja, lang-nl, lang-no, lang-pl, lang-pt, lang-pt_BR, lang-ru, lang-sk, lang-sq, lang-sv, lang-tr, lang-zh_CN, lang-zh_TW, travel-demo, tours, lang-ko, webapp]][InitPathsPropertySource]]
INFO info.magnolia.cms.beans.config.ConfigLoader 26.12.2016 17:28:29 -- Initializing content repositories
INFO info.magnolia.repository.DefaultRepositoryManager 26.12.2016 17:28:29 -- Loading JCR
INFO info.magnolia.repository.DefaultRepositoryManager 26.12.2016 17:28:29 -- Loading JCR magnolia
INFO info.magnolia.jackrabbit.ProviderImpl 26.12.2016 17:28:29 -- Loading repository at C:\Users\665564\MagnoliaRepositories\author\repositories\magnolia (config file: C:\Users\665564\magnolia-5.5\apache-tomcat-8.5.5\webapps\magnoliaAuthor\WEB-INF\config\repo-conf\jackrabbit-bundle-mssql-search-pm.xml) - cluster id: "<unset>"
DEBUG info.magnolia.jackrabbit.ProviderImpl 26.12.2016 17:28:29 -- No JNDI bound Repository found with name magnoliaAuthor, trying to initialize a new Repository
ERROR org.apache.jackrabbit.core.util.db.ConnectionHelper 26.12.2016 17:28:31 -- Failed to execute SQL (stacktrace on DEBUG log level): com.microsoft.sqlserver.jdbc.SQLServerException: Incorrect syntax near '$'.
ERROR org.apache.jackrabbit.core.util.db.ConnectionHelper 26.12.2016 17:28:31 -- Failed to execute SQL (stacktrace on DEBUG log level): com.microsoft.sqlserver.jdbc.SQLServerException: Incorrect syntax near '$'.
ERROR org.apache.jackrabbit.core.fs.db.DatabaseFileSystem 26.12.2016 17:28:31 -- failed to initialize file system
com.microsoft.sqlserver.jdbc.SQLServerException: Incorrect syntax near '$'.
at com.microsoft.sqlserver.jdbc.SQLServerException.makeFromDatabaseError(SQLServerException.java:217)
at com.microsoft.sqlserver.jdbc.SQLServerStatement.getNextResult(SQLServerStatement.java:1655)
at com.microsoft.sqlserver.jdbc.SQLServerStatement.doExecuteStatement(SQLServerStatement.java:885)
at com.microsoft.sqlserver.jdbc.SQLServerStatement$StmtExecCmd.doExecute(SQLServerStatement.java:778)
at com.microsoft.sqlserver.jdbc.TDSCommand.execute(IOBuffer.java:7505)
at com.microsoft.sqlserver.jdbc.SQLServerConnection.executeCommand(SQLServerConnection.java:2444)
at com.microsoft.sqlserver.jdbc.SQLServerStatement.executeCommand(SQLServerStatement.java:191)
at com.microsoft.sqlserver.jdbc.SQLServerStatement.executeStatement(SQLServerStatement.java:166)
at com.microsoft.sqlserver.jdbc.SQLServerStatement.execute(SQLServerStatement.java:751)
at org.apache.commons.dbcp.DelegatingStatement.execute(DelegatingStatement.java:264)
at org.apache.commons.dbcp.DelegatingStatement.execute(DelegatingStatement.java:264)
at org.apache.commons.dbcp.DelegatingStatement.execute(DelegatingStatement.java:264)
at org.apache.jackrabbit.core.util.db.ConnectionHelper.reallyExec(ConnectionHelper.java:307) .......
--------------------------------------
Please advice..

Thanks in advance