surrealdb / surrealist

Surrealist is the ultimate way to visually manage your SurrealDB database
https://surrealist.app/
MIT License
1.03k stars 73 forks source link

Written string ids containing symbols result in query error #342

Closed vitordhers closed 2 weeks ago

vitordhers commented 3 weeks ago

Describe the bug Folks, I've noticed that simply writing string ids on Surrealist result in errors. Please see screenshots below

To Reproduce Steps to reproduce the behavior:

  1. Go to queries tab;
  2. Try to write a query for a table with an unusual id (with symbols and such);
  3. Notice that it gives an error.
  4. Now, go to explorer, select a record, right click and click on "Use in SELECT query";
  5. Note that both strings are the exactly same string, even though only the second one doesn't throw any errors.

Expected behavior Naturally, writing or using the "Use in SELECT query" options shouldn't throw any error.

Environment:

Platform: Desktop
OS: linux
Architecture: x86_64
WebView: Mozilla/5.0 (X11; Ubuntu; Linux x86_64) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/17.0 Safari/605.1.15
Version: 2.1.1
Flags: featureFlags: false, models_view: true, apidocs_view: true, themes: false, newsfeed: true, database_version_check: true

Screenshot from 2024-06-14 15-42-27 Screenshot from 2024-06-14 15-42-36

macjuul commented 3 weeks ago

It appears to me the top query is incorrectly using parenthesis instead of the escape symbols ⟨ ⟩, which will indeed throw an error. Other than that record ids should be working fine 🙂

vitordhers commented 2 weeks ago

It's a different character, isn't it? 🤦 The different is so subtle I didn't realize. Thanks.