Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
GET KEYS FROM BucketName使用存储桶中的所有键对 datagrip 结果运行查询。
GET KEYS FROM BucketName
但是,当在 couchbase ui 或 java sdk 中查询相同的查询时,会使用syntax error - at KEYS. datagrip 是如何在不建立索引的情况下获取桶中所有文档的。
syntax error - at KEYS
基本上,我们的 JDBC 驱动程序检测GET KEYS FROM BucketName查询并使用RawManagerRequestCouchbase Java SDK 执行它们。所以你不能在 couchbase ui 中运行这个查询
RawManagerRequest
以下是我们的做法:https ://github.com/DataGrip/couchbase-jdbc-driver/blob/dev/driver/src/main/java/com/intellij/executor/GetBucketKeysExecutor.java
create primary index on bucketname; SELECT RAW META(b).id FROM bucketname AS b;