PDA

View Full Version : Embedded SQL in RPGLE requirements



Guest.Visitor
04-27-2004, 12:04 PM
Richard, If you want to embed SQL in RPG or CL then you'll need to buy the SQL development kit. Otherwise, you're out of luck. chuck Opinions expressed are not necessarily those of my employer. "Richard Rothe" <Richard_Rothe@mcpressonline.com> wrote in message news:6aeaac50.-1@WebX.WawyahGHajS... > At previous jobs, I have used embedded SQL in RPG. The SQL Developer Kit, among other things was required for it to be compiled. Is this still a requirment at V5R1 ? > > I am at a job now where we use ASC SEQUEL and they will not purchase the SQL Developer Kit. > > What I want to do is pass cursors back to client programs using stored procedures. How can I do that using native RPG to pass back record sets. > > If I cannot use embedded SQL because we don't have what is required to make it work, what other methods could I use to create stored procedures to return a record set ? > > SQLCLI ? Java stored procedures ? SQL Procedure Language ? Could I use WebSphere Developer Studio somehow to get around needing SQL Developer Kit ? > > Any suggestions would be appreciated.

dacust
04-27-2004, 01:51 PM
OK, here's a product of a brain exposed to too many chemicals during the 60's: If you really want to, you could use user controled files, build your string, call a CL and do an OPNQRYF with the string you built, do an OVRDBF and then return to your RPG where you open the file. It'd be kinda like the people that got Linux running on an X-box, Wine running under Linux, Mame running inside Wine. So now they can play the original Pac Man on their X-Box. Sick. But it'd work.

Guest.Visitor
04-28-2004, 04:54 AM
Your RPG pgm could create a qtemp file instead of a recordset. Then the client side could create its recordset by doing "select * from qtemp/file".

Absolutely_Nobody
04-28-2004, 04:54 AM
At previous jobs, I have used embedded SQL in RPG. The SQL Developer Kit, among other things was required for it to be compiled. Is this still a requirment at V5R1 ? I am at a job now where we use ASC SEQUEL and they will not purchase the SQL Developer Kit. What I want to do is pass cursors back to client programs using stored procedures. How can I do that using native RPG to pass back record sets. If I cannot use embedded SQL because we don't have what is required to make it work, what other methods could I use to create stored procedures to return a record set ? SQLCLI ? Java stored procedures ? SQL Procedure Language ? Could I use WebSphere Developer Studio somehow to get around needing SQL Developer Kit ? Any suggestions would be appreciated.