GraphQL - some DBs with similar names are not queryable

In a space I have created 2 DBs with similar names, differentiated only by spaces-

  1. “Inbar Test”
  2. “InbarTest”

Before creating the second one- the query “findInbarTests” worked to query the DB “Inbar Test”
But after creating the second one (which seems to be allowed in the platform), the same query “findInbarTests” now only queries the DB “InbarTest”.

I have also created a third DB “Inbar Test” (2 spaces) and this also worked without error (but of course cannot be queried either), and has the same display name as “Inbar Test” even though they are 2 different DBs- seems confusing. (Seems like creating a DB with only space differentiation should be disabled)

This leads me to another issue- when querying entities using GraphQL API, it is impossible to link back to the actual entity using just data returned by the GraphQL API (introspection + findXXX queries) - is there anyway to know what the DB name/ direct entity link is from data returned from the API?
Theoretically from the query name “findXXX” you should be able to parse what XXX (DB name) is, but because it truncates spaces- this is not possible.
Any advice would be appreciated.

1 Like

You’re right. The query itself determines the database, so it shouldn’t be necessary to provide the db in the response, but you are also correct that similarly named dbs can end up being indistinguishable :man_shrugging:

I don’t know of any fix, sorry

I think I’ve found a way using “description” of the return type of the query (during introspection)- some text returns containing the name of the DB exactly as it appears in the UI.

The bug also reproduces BTW if I create “inbar test” and “Inbar Test” (seems the non capitalised one is the only queryable one in GraphQL)