3 Replies Latest reply: Apr 11, 2013 8:36 AM by CraigB RSS

    QUERY_DATA_SOURCE_NAME

    884176
      Hi Everyone. I have to change the data source name of a block at runtime, ive placed this code in one of the button on when_button_pressed trigger.

      sql_string:= '(select a.cust_id
      , a.booking_date
      , a.claiming_code
      , a.appointment_id
      , b.first_name
      , b.middle_name
      , b.last_name
      , c.first_name||' '||c.last_name booking_agent
      , d.off_short_desc ffi_office
      , e.description appointment_outcome
      , f.off_short_desc appointment_where
      from tbl_appointment a
      , customer_external_data b
      , agent c
      , tbl_ffi_office d
      , tbl_appointment_outcome_ref e
      , tbl_ffi_office f
      where a.cust_id = b.cust_id
      and a.booking_agent = c.agent_id
      and a.ffi_office = d.off_id
      and a.appointment_outcome = e.appointment_outcome_id
      and a.appointment_where = f.off_id
      and a.appointment_outcome = 10)';

      set_block_property('tele_appointments',QUERY_DATA_SOURCE_NAME,sql_string);
      go_block('tele_appointments');
      clear_block;
      execute_query;

      But i'm getting this error.. please help me experts.. Thanks in advance.

      FRM-40505:Oracle error: Unable to perform query.