ifx_TSDW_dropWindow() function

The ifx_TSDW_dropWindow function removes time windows from a time series virtual table in a data mart.

Syntax

ifx_TSDW_dropWindow(accelerator_name varchar(128),
                    data_mart_name   varchar(128),
                    table_owner      varchar(32),
                    table_name       varchar(128),
                    begin_index      integer)
returns lvarchar;

ifx_TSDW_dropWindow(accelerator_name varchar(128),
                    data_mart_name   varchar(128),
                    table_owner      varchar(32),
                    table_name       varchar(128),
                    begin_stamp      datetime year to fraction(5))
returns lvarchar;
accelerator_name
The name of the accelerator.
datamart_name
The name of the data mart.
table_owner
The owner of the table.
table_name
The name of the table.
begin_index
The calendar index that identifies the first virtual partition that is included in the time window. The value must be greater than or equal 0.
begin_stamp
The time stamp that identifies the first virtual partition included in the time window. The value must be greater than or equal to the start time stamp of the calendar that is assigned to the table.

Usage

Run the ifx_TSDW_dropWindow function to remove a time window for a time series virtual table in a data mart.

You can remove time windows before or after the data mart is initially loaded, when the state of the data mart is LoadPending or Active.

If a time window is removed in an active data mart, the time series data is deleted immediately. Depending on the volume of data, this load can take a significant amount of time.

Return value

The ifx_TSDW_moveWindows() function returns the text string "The operation was completed successfully." or an error message.

Examples

The following examples remove time windows for the time series virtual table 'informix'.'ts_data_v' in data mart 'datamart_name' on accelerator 'demo_dwa'. A calendar with a start time stamp of '2010-01-01 00:00:00.00000' and a pattern of one month is set for this table. The time windows were created previously by using the ifx_TSDW_createWindow function.

The following example removes a time window that begins January 2011:
execute function ifx_TSDW_dropWindow(
  'demo_dwa', 'datamart_name', 'informix', 'ts_data_v',
  '2011-01'::datetime year to month);
The following example removes a time that begins March 2011:
execute function ifx_TSDW_createWindow(
  'demo_dwa', 'datamart_name', 'informix', 'ts_data_v', 14);