mirror of
https://github.com/FerretDB/documentdb.git
synced 2026-11-25 11:49:53 -05:00
### Does this PR have any customer impact? No ### Type (Feature, Refactoring, Bugfix, DevOps, Testing, Perf, etc) Refactoring ### Does it involve schema level changes? (Table, Column, Index, UDF, etc level changes) Yes ### Are you introducing any new config? If yes, do you have tests with and without them being set? No ### Release Note (Refer [Template](../docs/release_notes/pgmongo_template.md)) ### Description Move type/operator/schema files from pg_helio_api -> pg_documentdb Except udf files ---- #### AI description (iteration 1) #### PR Classification Code cleanup #### PR Summary This pull request moves type, operator, and schema files from the `pg_helio_api` directory to the `pg_documentdb` directory. - Updated SQL include paths in multiple `pg_helio_api` SQL files to reference `pg_documentdb` directory. - Modified `pgmongo` SQL files to include paths from `pg_documentdb` instead of `pg_helio_api`. - Adjusted `validate_helio_extension_state.sh` script to account for new file paths. - Updated `Makefile` in `pg_helio_api` to include the new directory structure. - Changed include paths in `pg_documentdb_distributed` and `pg_helio_distributed` C source files to reflect the new directory structure.
15 lines
633 B
SQL
15 lines
633 B
SQL
|
|
/* table that records committed writes and their logical transaction IDs */
|
|
CREATE SEQUENCE __API_CATALOG_SCHEMA__.collections_collection_id_seq AS bigint;
|
|
|
|
CREATE TABLE __API_CATALOG_SCHEMA__.collections (
|
|
database_name text not null,
|
|
collection_name text not null,
|
|
collection_id bigint not null unique default __API_SCHEMA_INTERNAL__.__EXTENSION_OBJECT__(_get_next_collection_id)(),
|
|
shard_key __CORE_SCHEMA__.bson,
|
|
collection_uuid uuid,
|
|
PRIMARY KEY (database_name, collection_name),
|
|
CONSTRAINT valid_db_coll_name CHECK (__API_SCHEMA_INTERNAL__.ensure_valid_db_coll(database_name, collection_name))
|
|
);
|
|
|