Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

About of the changing of table configuration #3

Closed
ogi-ts-shimizu opened this issue Nov 22, 2024 · 1 comment
Closed

About of the changing of table configuration #3

ogi-ts-shimizu opened this issue Nov 22, 2024 · 1 comment
Assignees
Labels
enhancement New feature or request question Further information is requested

Comments

@ogi-ts-shimizu
Copy link
Collaborator

Is your feature request related to a problem? Please describe.
We propose to change the table configuration for the following URL request.
DELETE /collections/{collectionId}/items/{mFeatureId}/tproperties/{tPropertyName}/{tValueId}

Describe the solution you'd like
now table configuration
issue2_1

proposed table configuration
issue2_2

Describe alternatives you've considered

Additional context
proposed table configuration DDL

CREATE EXTENSION IF NOT EXISTS PostGIS;
CREATE EXTENSION IF NOT EXISTS mobilitydb CASCADE;
CREATE EXTENSION IF NOT EXISTS "uuid-ossp";
-- Table collection
CREATE TABLE public.collection (
collection_id uuid NOT NULL DEFAULT uuid_generate_v4(),
collection_property jsonb NULL,
PRIMARY KEY (collection_id)
);

-- Table MovingFeature
CREATE TABLE public.mfeature (
collection_id uuid NOT NULL,
mfeature_id uuid NOT NULL DEFAULT uuid_generate_v4(),
mf_geometry geometry NULL,
mf_property jsonb NULL,
lifespan tstzspan NULL,
PRIMARY KEY (collection_id, mfeature_id),
FOREIGN KEY (collection_id) REFERENCES collection(collection_id)
);

-- Table TemporalGeometry
CREATE TABLE public.tgeometry (
collection_id uuid NOT NULL,
mfeature_id uuid NOT NULL,
tgeometry_id uuid NOT NULL DEFAULT uuid_generate_v4(),
tgeometry_property tgeompoint NULL,
tgeog_property tgeompoint NULL,
PRIMARY KEY (collection_id, mfeature_id, tgeometry_id),
FOREIGN KEY (collection_id, mfeature_id) REFERENCES mfeature(collection_id, mfeature_id)
);

-- Table TemporalProperty
CREATE TABLE public.tproperties (
collection_id uuid NOT NULL,
mfeature_id uuid NOT NULL,
tproperties_name text NOT NULL,
tproperty jsonb NULL,
PRIMARY KEY (collection_id, mfeature_id, tproperties_name),
FOREIGN KEY (collection_id, mfeature_id) REFERENCES mfeature(collection_id, mfeature_id)
);

-- Table TemporalPropertyValue
CREATE TABLE public.tvalue (
collection_id uuid NOT NULL,
mfeature_id uuid NOT NULL,
tproperties_name text NOT NULL,
tvalue_id uuid NOT NULL,
datetime_group int4 NOT NULL,
pvalue_float tfloat NULL,
pvalue_text ttext NULL,
PRIMARY KEY (collection_id, mfeature_id, tproperties_name, tvalue_id),
FOREIGN KEY (collection_id, mfeature_id, tproperties_name) REFERENCES tproperties(collection_id, mfeature_id, tproperties_name)
);

@ogi-ts-shimizu ogi-ts-shimizu added enhancement New feature or request question Further information is requested labels Nov 22, 2024
ogi-ts-shimizu added a commit to ogi-ts-shimizu/pygeoapi-ogi-mf-api that referenced this issue Nov 26, 2024
create new table for new api request

* DDL changed because new table was added

* Added new API requests and associated tests

* Adjusted file placement position
@TaehoonK
Copy link
Collaborator

TaehoonK commented Dec 12, 2024

This issue is resolved and merged into the main branch by a pull request (#1)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants