on 04-01-2019 10:22 AM
Hi,
Is it possible to define a system-versioned table in SAP HANA WEB IDE as a design time object. The SQL example below is functional - however not implemented in WEB IDE.
CREATE COLUMN TABLE account_history (
account_id INT,
account_owner_id NVARCHAR(10),
account_balance DOUBLE,
valid_from timestamp NOT NULL,
valid_to timestamp NOT NULL
);
CREATE COLUMN TABLE account (
account_id INT PRIMARY KEY,
account_owner_id NVARCHAR(10),
account_balance DOUBLE,
valid_from TIMESTAMP NOT NULL GENERATED ALWAYS AS ROW START,
valid_to TIMESTAMP NOT NULL GENERATED ALWAYS AS ROW END,
PERIOD FOR SYSTEM_TIME (valid_from, valid_to)
)
WITH SYSTEM VERSIONING HISTORY TABLE account_history;
Best regards,
Lars
Both tables have to be defined via a .hdbtable artifact. The system versioning relation between the tables has to be defined via a .hdbsystemversioning artifact.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thank you, Florian. I actually found an example provided by Thomas Jung ... for some reason it did not show in a google search --> SystemVersionedTest
User | Count |
---|---|
84 | |
23 | |
11 | |
9 | |
8 | |
5 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.