Loading…
Welcome to Common Europe Congress 2021 in Copenhagen, Denmark, the largest IBM Power Systems community gathering in Europe with in-depth workshops, deep dives, presentations. See the exciting agenda below; see more and register immediately: https://comeur.org/cec2021/ 
Back To Schedule
Sunday, October 31 • 14:00 - 17:00
Exploiting RPG in SQL and vice versa: (External) User Defined Functions and Tips for Dynamic SQL

Log in to save this to your schedule, view media, leave feedback and see who's attending!

Feedback form is now closed.
SQL is used for accessing data located in the database. But SQL is much more!
When embedding SQL in RPG we can decide between static (the final SQL Statement is known at compile time) and dynamic SQL (the final SQL Statement is not known before runtime).
The question is: When and how to use dynamic SQL and what to consider when using dynamic SQL?
Even though SQL is very powerful and we can profit from the features in RPG, there things that can be done easier with RPG!
So, the next question is: How can we use RPG in SQL?
Answer: By registering (RPG) programs and functions as Stored Procedures and User defined functions (UDF). External User Defined Table Functions (UDTF) are a little special, but once you have learned how to code them, you can use them for splitting data area contents into columns, read internally defined tables or consume user spaces populated by system APIs.

In this session you will learn when to use static and when to use dynamic SQL. You will get some tricks how to efficiently use dynamic SQL. Further you’ll learn how to register your RPG Functions as SQL Stored Procedures and User Defined Functions (UDF). Finally, you’ll get introduced in the use and coding of (external) User Defined Table Functions (UDTF).

Speakers
avatar for Birgitta Hauser

Birgitta Hauser

Database and Software Architect


Sunday October 31, 2021 14:00 - 17:00 CET
F18 - Room 18