Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Parse error in Query service

Former Member
0 Likes
379

Hello everybody,

I have some problems using the query service. here is the code


  data: lo_qry_manager type ref to if_os_query_manager,
        lo_qry type ref to if_os_query,
        lt_items type osreftab,
        l_tender_no type zs2tcvbeln_d,
        lo_agent type ref to zca_s2_tender_item,
        lx_error type ref to cx_root.

  lo_agent = zca_s2_tender_item=>agent.
  l_tender_no = header->get_zs2tcvbeln( ).

  lo_qry_manager = cl_os_system=>get_query_manager( ).
  lo_qry = lo_qry_manager->create_query( i_filter = 'ZS2TCVBELN = PAR1' ).

  try.
      lt_items = lo_agent->if_os_ca_persistency~get_persistent_by_query(
                                                             i_query = lo_qry
                                                             i_par1  = l_tender_no ).
    catch cx_root into lx_error.
  endtry.

The call to if_os_ca_persistency~get_persistent_by_query raises the exception CX_OS_QUERY_PARSE_ERROR with the text id ATTR_EXPECTED and ZS2TCVBELN als attribute found, that is somehow wrong.

This seems to be the case for all attributes of the related persistence class starting with the letter Z, all other attributes seem to work fine.

any ideas?

thanks in advance,

best regards,

Hans Hohenfeld

1 REPLY 1
Read only

Former Member
0 Likes
306

Unbelievable, fixed by note 1157635...