Document database backed by keyvalue storage P&L: -7 (≃ -62 USD)
I am interested in database technology and distributed systems.
I have an experimental python project which is less than 1000 lines and supports basic SQL and SQL inner joins and basic Cypher graph database queries and keyvalue storage. There is no persistence layer.
On the linked website page from this project which is GitHub issues I am talking how I plan to implement document storage so that JSON documents can be mapped to individual keys and joined with SQL queries.
我花了几个小时来解决这个问题的其余部分,并在完成保存文档后进行文档检索。
这使您可以保存和检索 JSON 文档
插入的文档数据也可以通过 SQL 查询。
尚不支持针对文档的联接,但我计划实施此功能。
I spent a few hours working on the remainder of this problem and got documnent retrieval working after finishing save document.
This lets you save and retrieve JSON documents
The document data inserted is also queryable by SQL.
Joins against documents are not yet supported but I plan to implement this.
我设法存储了一个 JSON 文档,并使用 SQL 插入器插入了该文档。理论上,该对象可以通过 SQL 查询
{
“项目”:[(“名称”:“项目1”),(“名称”:“项目2”)],
“子对象”:{“子对象键”:“值”} }
I managed to store a JSON document and I used the SQL inserter to insert the document. In theory the object is queryable by SQL
{ "items": [("name": "item1"), ("name": "item2")], "subobject": {"subobject_key": "value"} }
⬜️ 需要将 JSON 文档映射到数字,以便“文档 id 0 hobbies[0].name=sam”变为 0@0.0=sam”,这允许通过扫描数字之间的一系列键来进行有效检索。 ⬜️需要编写代码将数字转回字段名称 ⬜️需要集成键空间优化器,因为我们重新排序数字以提高跨列表连接的效率,例如文档 0 = {"hobbies":{("name": "God"),{"name": "databases"), {" name": "computers")}) hobbies 可能是 0,name 可能是 1,我们有 3 个列表项 0、1、2 我们希望所有相同类型的列表索引在排序迭代器中相邻,所以我们翻转它们到最后所以 0@0[1]="God" 变成 0@1.0, 0@1.1 0@1.2 ⬜️ 需要为用于 SQL 连接的内容创建键值 ⬜️ 需要创建一个文档,定义人们期望在 JSON 文档上执行的连接
⬜️ need to map a JSON document to numbers so "document id 0 hobbies[0].name=sam" becomes 0@0.1=sam" this allows for efficient retrievals by scanning a range of keys between numbers. ⬜️need to write code to turn numbers back into field names ⬜️need to integrate keyspace optimiser, as we reorder numbers for efficiency of joins across lists for example document 0 = {"hobbies":{("name": "God"),{"name": "databases"), {"name": "computers")}) hobbies might be 0, name might be 1 and we have 3 list items 0, 1, 2 we want all list indexes of the same kind to be adjacent in the sort iterator, so we flip them to the end so 0@0[1]="God" becomes 0@1.0, 0@1.1 0@1.2 ⬜️ need to create keyvalues for what is used for SQL joins ⬜️ need to create a document which defines the joins that people expect to do on a JSON document
我目前处于设计阶段。我正在寻找一种有效的方法来有效地进行结构化连接和扫描集合的匹配键。
I am currently in design phase. I am looking for an efficient approach to structured joins and scanning matching keys of collections efficiently.
太好了,你开始了一个项目,[按时间顺序]!很有意思。我将深入探讨您对实现和代码的想法。也许我们也可以邀请对相关技术感兴趣或从事相关技术工作的人来这里。
Great you starting a project, [chronological]! Very interesting. I'll have a deep dive into your thoughts of implementation and code. Perhaps we can also invite here people interested or working on related technology.