Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Note
iconfalse
titleNote

LANSA Composer does not guarantee that any form of SQL statement that is valid for your target database can successfully be executed through the SQL database activities, nor that every form of SQL stored procedure can successfully be executed.
Nor will it be possible to successfully address every possible data type in your database.  Since processing sequence variables that might be used to pass or receive data to the SQL database are untyped, not all conversions can be successful or yield useful results.  It is your responsibility to ensure that any data passed through the SQL database suite of activities is in a form that can be accepted and processed by both the JDBC driver and the target database.


Anchor
Example Processing Sequences using the SQL database activities
Example Processing Sequences using the SQL database activities
Example Processing Sequences using the SQL database activities

Refer to the following example processing sequences supplied with LANSA Composer for working (*) examples that use the SQL database activities.  (*)  Note that some setup will be required on your system to enable these examples to execute successfully.  Refer to the notes accompanying the example processing sequences for details:

  • EXAMPLE_SQL01: Example of using the SQL_QUERY activity
  • EXAMPLE_SQL02: Example of using the SQL_UPDATE activity
  • EXAMPLE_SQL03: Example of using the SQL_CALLQRYCSV activity

Related SQL database activities

The SQL_CONNECT activity returns a "handle" that can then be passed on to the other SQL database activities to accomplish a range of database tasks.  The full suite of SQL database activities are briefly described below:

...

  • Use the following activities to query the database:

    FOR_EACH_SQL_QUERY

    Query database using SQL and iterate the results~

    SQL_QUERY

    Query database using SQL

    SQL_QUERYTOCSV

    Query database using SQL to output CSV file

  • Use the following activities to perfom insert, update and delete operations in the database:

    SQL_UPDATE

    Update database using SQL

  • Use the following activities to execute an SQL stored procedure in the database:

    SQL_CALL

    Execute an SQL stored procedure

    SQL_CALLQRYCSV

    Query database using an SQL stored procedure to CSV

    SQL_CALLQUERY

    Query database using an SQL stored procedure

  • Use the following activities to implement transaction control relating to any database insert, update or delete operations you have performed:

    SQL_COMMIT

    Commit a database transaction using SQL

    SQL_ROLLBACK

    Rollback a database transaction using SQL

...