2 Replies Latest reply: Jul 10, 2012 8:07 AM by Neeraj Sehgal RSS

    How to pass dynamic values to JDBC Database adapter in PureSQL operation?

    905784
      I want to fetch the records from the table via JDBC database adapter with the criteria but I should not hardcode the values inside my query. I am using Execute by PureSQL operation. Values might change in future and it is the reason I should not hardcode the values and instead I should pass it dynamically.

      This is my query:

      SELECT FROM Table0 t0, Table1 t1 WHERE t0.Field1= 'ABC' AND t0.Field2= 'DEF' AND t0.Field3 = 'CBA' AND t1.FLAG IS NULL AND t1.Field1 = t0.Field4*

      The values 'ABC', 'DEF', 'CBA', 'NULL' are not fixed and it can be changed. Hence, I need to pass the values for these fields dynamically. What must be passed in the query and where to pass the User Defined Values during the run time.

      Please can anyone suggest how to resolve this. I am using SOA 11g.

      Thanks in advance.