quiverdb 0.12.7 → 0.12.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -62,8 +62,9 @@ bun run example.ts
62
62
 
63
63
  ### Lifecycle
64
64
 
65
- - `Database.fromSchema(dbPath, schemaPath)` -- Create database from SQL schema file
66
- - `Database.fromMigrations(dbPath, migrationsPath)` -- Create database from migrations directory
65
+ - `Database.fromSchema(dbPath, schemaPath, options?)` -- Create database from SQL schema file
66
+ - `Database.fromMigrations(dbPath, migrationsPath, options?)` -- Create database from migrations directory
67
+ - `Database.open(dbPath, options?)` -- Open an existing database file; the schema loads on first use
67
68
  - `Database.validateMigrations(migrationsPath)` -- Validate a migrations directory (every `up.sql`, then every `down.sql`, ending with no table left behind) in-memory; throws on failure
68
69
  - `close()` -- Close the database connection
69
70
 
@@ -74,6 +75,16 @@ bun run example.ts
74
75
  - `deleteElement(collection, id)` -- Delete element by ID
75
76
  - `updateElementByLabel(collection, label, data)` -- Update element by label
76
77
  - `deleteElementByLabel(collection, label)` -- Delete element by label
78
+ - `updateRelation(collectionFrom, collectionTo, relationType, id, targetLabel)` -- Point a scalar
79
+ relation at the element labelled `targetLabel` (`null` clears it)
80
+ - `updateRelationByLabel(collectionFrom, collectionTo, relationType, label, targetLabel)` -- Same,
81
+ addressing the element by label
82
+ - `updateVectorGroup(collection, group, id, data)` -- Replace an element's rows in one named vector
83
+ group (`{}` clears it)
84
+ - `updateVectorGroupByLabel(collection, group, label, data)` -- Same, addressing the element by label
85
+ - `updateSetGroup(collection, group, id, data)` -- Replace an element's rows in one named set group
86
+ (`{}` clears it)
87
+ - `updateSetGroupByLabel(collection, group, label, data)` -- Same, addressing the element by label
77
88
 
78
89
  ### Read (bulk)
79
90
 
@@ -127,6 +138,18 @@ bun run example.ts
127
138
 
128
139
  - `readTimeSeriesGroup(collection, group, id)` -- Read time series data for an element
129
140
  - `updateTimeSeriesGroup(collection, group, id, data)` -- Write time series data for an element
141
+ (`{}` clears it)
142
+ - `updateTimeSeriesGroupByLabel(collection, group, label, data)` -- Same, addressing the element by
143
+ label
144
+ - `readTimeSeriesRow(collection, group, attribute, dateTime)` -- One value per element: the last
145
+ non-null value at or before `dateTime`, or `null` if there is none
146
+ - `upsertTimeSeriesRow(collection, group, id, row)` -- Insert or replace one row, keyed by its
147
+ dimension value
148
+ - `upsertTimeSeriesRowByLabel(collection, group, label, row)` -- Same, addressing the element by label
149
+ - `hasTimeSeriesFiles(collection)` -- Check whether the collection has a time series files table
150
+ - `listTimeSeriesFilesColumns(collection)` -- List the time series files columns
151
+ - `readTimeSeriesFiles(collection)` -- Read the file paths (`null` for an unset column)
152
+ - `updateTimeSeriesFiles(collection, data)` -- Write the file paths
130
153
 
131
154
  ### Query
132
155
 
@@ -162,7 +185,9 @@ as an exact INTEGER, a `boolean` as the INTEGER 1 or 0).
162
185
 
163
186
  ### Introspection
164
187
 
165
- - `describe()` -- Print schema info to stdout
188
+ - `describe()` -- Whole-database text report (returns a string)
189
+ - `describeCollection(collection)` -- One collection's structure (returns a string)
190
+ - `summarizeCollection(collection)` -- Per-attribute null/value summary (returns a string)
166
191
  - `isHealthy()` -- Check database health
167
192
  - `path()` -- Get database file path
168
193
  - `currentVersion()` -- Get current schema version
@@ -178,11 +203,13 @@ as an exact INTEGER, a `boolean` as the INTEGER 1 or 0).
178
203
 
179
204
  Exported types available for TypeScript consumers:
180
205
 
181
- - `ScalarValue` -- `number | bigint | string | null`
182
- - `ArrayValue` -- `number[] | bigint[] | string[]`
206
+ - `ScalarValue` -- `number | bigint | boolean | string | null` (a `boolean` is stored as INTEGER 1/0)
207
+ - `ArrayValue` -- `number[] | bigint[] | boolean[] | string[]`
183
208
  - `Value` -- `ScalarValue | ArrayValue`
184
209
  - `ElementData` -- `Record<string, Value | undefined>`
185
210
  - `QueryParam` -- `number | bigint | boolean | string | null`
211
+ - `GroupColumns` -- `Record<string, (number | bigint | string | boolean | null)[]>`, the column-oriented
212
+ payload of `updateTimeSeriesGroup` / `updateVectorGroup` / `updateSetGroup` (and their `ByLabel` forms)
186
213
  - `QuiverError` -- Error class for all Quiver operations
187
214
  - `ScalarMetadata` -- Scalar attribute metadata
188
215
  - `GroupMetadata` -- Vector/set/time series group metadata
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "quiverdb",
3
- "version": "0.12.7",
3
+ "version": "0.12.9",
4
4
  "license": "MIT",
5
5
  "repository": {
6
6
  "type": "git",