mirror of
https://github.com/DeNNiiInc/dbgate.git
synced 2026-05-01 17:53:59 +00:00
nosql db WIP
This commit is contained in:
14
packages/types/dbinfo.d.ts
vendored
14
packages/types/dbinfo.d.ts
vendored
@@ -94,7 +94,19 @@ export interface TableInfo extends DatabaseObjectInfo {
|
|||||||
__isDynamicStructure?: boolean;
|
__isDynamicStructure?: boolean;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface CollectionInfo extends DatabaseObjectInfo {}
|
export interface CollectionInfo extends DatabaseObjectInfo {
|
||||||
|
// all known columns with definition (only used in Cassandra)
|
||||||
|
knownColumns?: ColumnInfo[];
|
||||||
|
|
||||||
|
// unique combination of columns (should be contatenation of partitionKey and clusterKey)
|
||||||
|
uniqueKey?: ColumnReference[];
|
||||||
|
|
||||||
|
// partition key columns
|
||||||
|
partitionKey?: ColumnReference[]
|
||||||
|
|
||||||
|
// unique key inside partition
|
||||||
|
clusterKey?: ColumnReference[];
|
||||||
|
}
|
||||||
|
|
||||||
export interface ViewInfo extends SqlObjectInfo {
|
export interface ViewInfo extends SqlObjectInfo {
|
||||||
columns: ColumnInfo[];
|
columns: ColumnInfo[];
|
||||||
|
|||||||
@@ -34,9 +34,11 @@ class Analyser extends DatabaseAnalyser {
|
|||||||
...collections.map((x, index) => ({
|
...collections.map((x, index) => ({
|
||||||
pureName: x.name,
|
pureName: x.name,
|
||||||
tableRowCount: stats[index]?.count,
|
tableRowCount: stats[index]?.count,
|
||||||
|
uniqueKey: [{ columnName: '_id' }],
|
||||||
})),
|
})),
|
||||||
...views.map((x, index) => ({
|
...views.map((x, index) => ({
|
||||||
pureName: x.name,
|
pureName: x.name,
|
||||||
|
uniqueKey: [{ columnName: '_id' }],
|
||||||
})),
|
})),
|
||||||
],
|
],
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user