LAE

Welcome to the LAE community!  Please feel free to start a discussion in the discussion tab or join in a conversation.

Discussions

Members

Resources

Events

 View Only
  • 1.  JDBC Query Node

    Employee
    Posted 05-22-2018 10:18

    Note: This was originally posted by an inactive account. Content was preserved by moving under an admin account.

    Originally posted by: mw9286

    How do you create a JDBC Query Node that will read in a file to a sql query.

    I have a db execute node, but I don't know how to configure it for a JDBC query. The db execute node has a general tab where the statement reads the following and then actual query on the parameter 1 tab.

    General tab:
    sqlSelect(1,
    "{{^query^}}",
    BAN.str().trim())

    Parameter 1 tab

    select * from xyz where BAN = :1


  • 2.  RE: JDBC Query Node

    Employee
    Posted 05-22-2018 11:28

    Note: This was originally posted by an inactive account. Content was preserved by moving under an admin account.

    Originally posted by: stonysmith

    The DB_Execute node will not talk to JDBC. You would use the JDBC_Query (or JDBC_Execute) node instead.

    In the query you'd put

    select * from xyz where BAN = :1

    and in the BIND_FIELDS parameter (at the bottom), just put
    BAN

    You'll most likely have to do the .str().trim() functions in a filter before this node.


  • 3.  RE: JDBC Query Node

    Employee
    Posted 06-08-2018 08:57

    Note: This was originally posted by an inactive account. Content was preserved by moving under an admin account.

    Originally posted by: mw9286

    Hi Stoney: I am getting the following error.

    oa.customer_id = :1". Cause: Unable to parse query text: unexpected char: ':'. On line 1, column 697. [parser-2904201] [Log ID: 739ed662-6330-413a-98c6-55f4543421b6] [jdbc-1906510]


  • 4.  RE: JDBC Query Node

    Employee
    Posted 06-08-2018 09:05

    Note: This was originally posted by an inactive account. Content was preserved by moving under an admin account.

    Originally posted by: stonysmith

    The exact syntax depends entirely upon the database driver.

    Try this next:
    select * from xyz where BAN = ?


  • 5.  RE: JDBC Query Node

    Employee
    Posted 06-08-2018 09:12

    Note: This was originally posted by an inactive account. Content was preserved by moving under an admin account.

    Originally posted by: mw9286

    That worked..

    Thank you