reql

    0熱度

    1回答

    我有一個.itemId來自第三方,不是由我生成的。 我需要在數據庫中查找它並更新或插入它,如果它不存在。 我一直使用從食譜這個例子嘗試:https://www.rethinkdb.com/docs/cookbook/javascript/#manipulating-documents const res = await this.r.table('products').filter({itemId

    0熱度

    1回答

    我有這個JSON文件: { userId: xx, followedAuthors: [ { authorId: abc, timestamp: 123 }, { authorId: xyz, timestamp: 456 }, ] } 當用戶要遵循一個作家,我想寫出檢查,如果該作者已經跟隨查詢,檢查id,以及它是否將新的後續作者追加到數組中

    0熱度

    1回答

    我一直在創建一個數據庫與Rethinkdb。這裏是我的數據庫格式: { "Email": [email protected], » "Password": "totallyahash1234" , "UserName": "CoolDude3" , "id": "6a4bb963-687a-48c2-b3f0-2e91965d3515" , "Projects": { "

    2熱度

    1回答

    我在RethinkDB中更新數組有問題。我的JSON結構如下所示。 { "LOG_EVENT": { "ATTRIBUTES": [ { "ATTRIBUTE1": "TYPE", "VALUE": "ORDER" }, { "ATTRIBUTE2": "NUMBER",

    0熱度

    2回答

    我正在測試一個在RethinkDB數據庫的多個表中插入或刪除數據的API。爲了在使用API​​時監視數據庫發生了什麼,我想打印所有表中的更改。 這裏是我想要實現一些「僞代碼」: import rethinkdb as r # Prior to running this script, run "rethinkdb --port-offset 1" at the command line co

    0熱度

    1回答

    我想連接兩個表並使用連接表寫入get url(在連接的表上進行獲取,發佈,刪除)。 我知道如何與單個表做(例如): https://www.rethinkdb.com/docs/table-joins/ r.table("employees").eq_join("company_id", r.table("companies")).zip().run() 返回以下結果: { "id": "0

    1熱度

    1回答

    我想以簡單的方式在RethinkDB中使用連接。 這是我試過了,像顯示在文檔查詢: r.table('users')('inventory').default([]).eqJoin('name', r.table('prices')).without({ right: 'name' }).zip() 我會爲每個用戶像這樣的項目清單: [ { id: "user

    0熱度

    1回答

    我有一個由Robinhood Stock Orders組成的RethinkDB表。相關的字段有: side(無論是buy或sell) state(我只想找filled訂單) price(訂單的平均美元價格) quantity(出售或購買的股份數量) 我只是想了解我的訂單歷史記錄中每隻股票的所有時間盈虧。 我有以下工作查詢,它​​告訴我所有賣單的價格,通過股票代碼分組: r.db('robinhoo

    1熱度

    1回答

    我有一個表中rethinkdb ReQL濾波器和匹配命令,其中每行有下列結構 - { 'name':'clustername', 'services':[ { 'name':'service1' }, { 'name':'service2' } ] } 我運行一個查詢過濾這樣 r.table('cl

    1熱度

    1回答

    我有以下ReQL查詢識別不同的地址,但似乎無法添加not()方法來得到相反的結果。 r.db('mydb').table('users').orderBy(r.desc('email')).without('id').distinct()