• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

CF Data Source: I cannot connect to a different database other than the one specified in my initial setup

New Here ,
Aug 22, 2018 Aug 22, 2018

Copy link to clipboard

Copied

I have CF installed and configured to worked with MongoDB using a Data Direct JDBC connector.

I created a data source and specified a sample database name in the JDBC URL and all works fine.

The problem now is, I want to use a different database, the actual one for my CF application, but when I edit the database name in the JDBC URL, I get the following error and when I change it back to the sample database name, it works fine:

Connection verification failed for data source: OkDataSource3

java.sql.SQLSyntaxErrorException: [DataDirect][MongoDB JDBC Driver][MongoDB]syntax error or access rule violation: invalid schema name: NEWDB

The root cause was that: java.sql.SQLSyntaxErrorException: [DataDirect][MongoDB JDBC Driver][MongoDB]syntax error or access rule violation: invalid schema name: NEWDB

The database name is correct.

I have tried creating a new data source with my preferred database, I get the same error too.

I am also unable to connect to a different Collection in the sample database other than the very first one I used.

The summary of my current issue is, I have different databases in my MongoDB Compass but I can't seem to connect to any of them other than the very first sample database I used when I created the data source. Also, when I edit the columns in the Collection i'm using in the sample database, my application doesn't seem to recognize the change.

Please help, what am I not doing right?

TOPICS
Database access

Views

442

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
no replies

Have something to add?

Join the conversation
Resources
Documentation