/AWS1/IF_CWL=>GETSCHEDULEDQUERY()¶
About GetScheduledQuery¶
Retrieves details about a specific scheduled query, including its configuration, execution status, and metadata.
Method Signature¶
METHODS /AWS1/IF_CWL~GETSCHEDULEDQUERY
IMPORTING
!IV_IDENTIFIER TYPE /AWS1/CWLSCHEDULEDQUERYID OPTIONAL
RETURNING
VALUE(OO_OUTPUT) TYPE REF TO /aws1/cl_cwlgetschddqueryrsp
RAISING
/AWS1/CX_CWLACCESSDENIEDEX
/AWS1/CX_CWLINTERNALSERVEREX
/AWS1/CX_CWLRESOURCENOTFOUNDEX
/AWS1/CX_CWLTHROTTLINGEX
/AWS1/CX_CWLVALIDATIONEX
/AWS1/CX_CWLCLIENTEXC
/AWS1/CX_CWLSERVEREXC
/AWS1/CX_RT_TECHNICAL_GENERIC
/AWS1/CX_RT_SERVICE_GENERIC.
IMPORTING¶
Required arguments:¶
iv_identifier TYPE /AWS1/CWLSCHEDULEDQUERYID /AWS1/CWLSCHEDULEDQUERYID¶
The ARN or name of the scheduled query to retrieve.
RETURNING¶
oo_output TYPE REF TO /aws1/cl_cwlgetschddqueryrsp /AWS1/CL_CWLGETSCHDDQUERYRSP¶
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->getscheduledquery( |string| ).
This is an example of reading all possible response values
lo_result = lo_result.
IF lo_result IS NOT INITIAL.
lv_arn = lo_result->get_scheduledqueryarn( ).
lv_scheduledqueryname = lo_result->get_name( ).
lv_scheduledquerydescripti = lo_result->get_description( ).
lv_querylanguage = lo_result->get_querylanguage( ).
lv_querystring = lo_result->get_querystring( ).
LOOP AT lo_result->get_loggroupidentifiers( ) into lo_row.
lo_row_1 = lo_row.
IF lo_row_1 IS NOT INITIAL.
lv_loggroupidentifier = lo_row_1->get_value( ).
ENDIF.
ENDLOOP.
lv_scheduleexpression = lo_result->get_scheduleexpression( ).
lv_scheduletimezone = lo_result->get_timezone( ).
lv_starttimeoffset = lo_result->get_starttimeoffset( ).
lo_destinationconfiguratio = lo_result->get_destinationconfiguration( ).
IF lo_destinationconfiguratio IS NOT INITIAL.
lo_s3configuration = lo_destinationconfiguratio->get_s3configuration( ).
IF lo_s3configuration IS NOT INITIAL.
lv_s3uri = lo_s3configuration->get_destinationidentifier( ).
lv_rolearn = lo_s3configuration->get_rolearn( ).
lv_accountid = lo_s3configuration->get_owneraccountid( ).
lv_kmskeyid = lo_s3configuration->get_kmskeyid( ).
ENDIF.
ENDIF.
lv_scheduledquerystate = lo_result->get_state( ).
lv_timestamp = lo_result->get_lasttriggeredtime( ).
lv_executionstatus = lo_result->get_lastexecutionstatus( ).
lv_timestamp = lo_result->get_schedulestarttime( ).
lv_timestamp = lo_result->get_scheduleendtime( ).
lv_rolearn = lo_result->get_executionrolearn( ).
lv_timestamp = lo_result->get_creationtime( ).
lv_timestamp = lo_result->get_lastupdatedtime( ).
ENDIF.