Quantcast
Channel: SCN : Discussion List - SAP HANA Developer Center
Viewing all articles
Browse latest Browse all 6412

Series Table : meaning of declaring it as Equidistant missing elements not allowed

$
0
0

In Series data, we can define a table as the following :

 

create column table SERIES_DATA.MY_SERIES_TABLE (

  id INT,

  ts TIMESTAMP,

  value DECIMAL(4,3)

  ) SERIES (

  SERIES KEY (id)

  PERIOD FOR SERIES(ts)

  EQUIDISTANT INCREMENT BY INTERVAL 1 HOUR MISSING ELEMENTS NOT ALLOWED

);

 

 

 

I insert some value in the table like this.

 

Insert into "SERIES_DATA"."MY_SERIES_TABLE" select 1, GENERATED_PERIOD_START, 7.0 from SERIES_GENERATE_TIMESTAMP ('INTERVAL 1 HOUR', '2010-01-01', '2011-01-01', null, null, null);

 

By meaning of keyword missing elements not allowed, I thought that the table would not allow any missing elements withing the series that its timestamp column values are forming.

 

The definition as per developer guide is the following :

 

For equidistant series, there should be no gaps in the rows associated with the elements of the series when the series is defined to exclude missing values.

 

The values inserted are equidistant.

 

Now, going by the assumption , I thought deletion of any row will not be allowed as it will break 'missing elements not allowed' property. But I am able to delete a row.

 

 

I know I am missing something very silly here. Could someone help me out in this? What is the difference in behaviour if I declare a table as MISSING ELEMENTS NOT ALLOWED and another as MISSING ELEMENTS ALLOWED.

 

So far I see I am being restricted to insert a value if that breaks the interval. Other than that, I am able to delete and update in both kinds of table.

 

Regards,

Subhankar


Viewing all articles
Browse latest Browse all 6412

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>