Skip to content

/AWS1/IF_IOS=>BATCHDELETEDATASETDATASEGS()

About BatchDeleteDatasetDataSegments

Deletes a batch of data segments from a session dataset. Deleting a data segment deletes the underlying time series data for the segment's time range.

Method Signature

METHODS /AWS1/IF_IOS~BATCHDELETEDATASETDATASEGS
  IMPORTING
    !IV_DATASETID TYPE /AWS1/IOSID OPTIONAL
    !IV_WORKSPACENAME TYPE /AWS1/IOSWORKSPACENAME OPTIONAL
    !IT_DELETEDATASEGMENTENTRIES TYPE /AWS1/CL_IOSDELETEDATASEGENTRY=>TT_DELETEDATASEGMENTENTRIES OPTIONAL
    !IV_CLIENTTOKEN TYPE /AWS1/IOSCLIENTTOKEN OPTIONAL
  RETURNING
    VALUE(OO_OUTPUT) TYPE REF TO /aws1/cl_iosbtcdelsdatasegrsp
  RAISING
    /AWS1/CX_IOSCNFLCTOPERATIONEX
    /AWS1/CX_IOSINTERNALFAILUREEX
    /AWS1/CX_IOSINVALIDREQUESTEX
    /AWS1/CX_IOSRESOURCENOTFOUNDEX
    /AWS1/CX_IOSTHROTTLINGEX
    /AWS1/CX_IOSCLIENTEXC
    /AWS1/CX_IOSSERVEREXC
    /AWS1/CX_RT_TECHNICAL_GENERIC
    /AWS1/CX_RT_SERVICE_GENERIC.

IMPORTING

Required arguments:

iv_datasetid TYPE /AWS1/IOSID /AWS1/IOSID

The ID of the session dataset from which to delete data segments.

iv_workspacename TYPE /AWS1/IOSWORKSPACENAME /AWS1/IOSWORKSPACENAME

The name of the workspace that contains the dataset.

it_deletedatasegmententries TYPE /AWS1/CL_IOSDELETEDATASEGENTRY=>TT_DELETEDATASEGMENTENTRIES TT_DELETEDATASEGMENTENTRIES

The list of data segment entries to delete.

Optional arguments:

iv_clienttoken TYPE /AWS1/IOSCLIENTTOKEN /AWS1/IOSCLIENTTOKEN

A unique, case-sensitive identifier that you provide to ensure that the request is idempotent. If you retry a request that completed successfully using the same client token, the retry succeeds without performing any further actions.

RETURNING

oo_output TYPE REF TO /aws1/cl_iosbtcdelsdatasegrsp /AWS1/CL_IOSBTCDELSDATASEGRSP

Examples

Syntax Example

This is an example of the syntax for calling the method. It includes every possible argument and initializes every possible value. The data provided is not necessarily semantically accurate (for example the value "string" may be provided for something that is intended to be an instance ID, or in some cases two arguments may be mutually exclusive). The syntax shows the ABAP syntax for creating the various data structures.

DATA(lo_result) = lo_client->batchdeletedatasetdatasegs(
  it_deletedatasegmententries = VALUE /aws1/cl_iosdeletedatasegentry=>tt_deletedatasegmententries(
    (
      new /aws1/cl_iosdeletedatasegentry(
        io_endtimestamp = new /aws1/cl_iostimeinnanos(
          iv_offsetinnanos = 123
          iv_timeinseconds = 123
        )
        io_starttimestamp = new /aws1/cl_iostimeinnanos(
          iv_offsetinnanos = 123
          iv_timeinseconds = 123
        )
        iv_timeseriesid = |string|
      )
    )
  )
  iv_clienttoken = |string|
  iv_datasetid = |string|
  iv_workspacename = |string|
).

This is an example of reading all possible response values

lo_result = lo_result.
IF lo_result IS NOT INITIAL.
  lv_id = lo_result->get_datasetid( ).
  lv_version = lo_result->get_datasetversion( ).
  LOOP AT lo_result->get_errors( ) into lo_row.
    lo_row_1 = lo_row.
    IF lo_row_1 IS NOT INITIAL.
      lv_id = lo_row_1->get_timeseriesid( ).
      lo_timeinnanos = lo_row_1->get_starttimestamp( ).
      IF lo_timeinnanos IS NOT INITIAL.
        lv_timeinseconds = lo_timeinnanos->get_timeinseconds( ).
        lv_offsetinnanos = lo_timeinnanos->get_offsetinnanos( ).
      ENDIF.
      lo_timeinnanos = lo_row_1->get_endtimestamp( ).
      IF lo_timeinnanos IS NOT INITIAL.
        lv_timeinseconds = lo_timeinnanos->get_timeinseconds( ).
        lv_offsetinnanos = lo_timeinnanos->get_offsetinnanos( ).
      ENDIF.
      lv_datasegmenterrorcode = lo_row_1->get_errorcode( ).
      lv_datasegmenterrormessage = lo_row_1->get_errormessage( ).
    ENDIF.
  ENDLOOP.
ENDIF.