SQLRPGLE Questions


RPGLE – Provide One-to-Many mapping
hi, I want to provide one-to-many mapping . consider 1 example, i have one-to-one mapping in Agent and Depot. bt i want, one Agent & Many Depot mapping. Means we can have one Agent with many Depot. using RPGLE or SQLRPGLE. I have one subfile where we can retrieve Agent, Agent name, and Depot from [...]

Answer Question   |  March 16, 2009  11:23 AM
RPGLE, RPGLE Program, SQLRPGLE
asked by:
5 pts.

RPGLE Stored Proc to Reporting Services
Have SQLRPGLE program set-up to use cursor to return result set, want to use this to return table to MS Reporting Services get error message “low-order nibble of byte array offset 2451 is not valid. Byte Value OO. What does this mean and why not data back to client?

Answer Question   |  July 3, 2009  10:21 PM
Reporting Services 2005, RPGLE, SQL stored procedures, SQLRPGLE
asked by:
65 pts.

Can embedded SQL in a SQLRPGLE program be used as a stored procedure?
I am successfully using (external) stored procedures with many RPGLE programs. (Some of these are SQLRPGLE programs because they return a result set.) All of this works fine. But if I try to replace some of the RPG I/O in a RPGLE program with embedded SQL, creating a SQLRPGLE program, and run it as a [...]

Answer Question   |  January 15, 2009  10:09 PM
Embedded SQL, iSeries development, iSeries RPG programming, RPG, RPGLE, SQL, SQLRPGLE, Stored Procedures
asked by:
20 pts.

Using the SQL IN clause in SQLRPGLE
Can I use a variable with the IN clause in an iSeries SQLRPGLE program? Can I use: WHERE CUSTID IN(:CUSTNUMS) Instead of: WHERE CUSTID IN(145,1600,352)

Answer Question   |  December 19, 2008  10:09 PM
IN statement, iSeries, iSeries development, SQL statements, SQLRPGLE, WHERE statement
asked by:
5 pts.

where does the file get created in AS/400 system when we fire embedded INSERT query in an RPGLE program
we are inserting deptid in departments table using the following INSERT statement: INSERT INTO departments (department_id, department_name ) VALUES (30, ‘:Purchasing’); so where does the departments file get created in As/400 system? when we are doing a runqry on departments file, it is giving the error that the file is not present in the library [...]

Answer Question   |  November 12, 2008  2:14 PM
AS/400, INSERT statement, RPGLE, RPGLE Program, SQLRPGLE
asked by:
695 pts.

Can you embed SQL statements in RPG program
I am new to AS/400 and we have a project wherein we have to display the records grouped by some fields. Is it possible to write sql statements within RPG program?? How???

Answer Question   |  August 22, 2010  4:48 AM
Embedded SQL, RPG, SQL, SQLRPGLE
asked by:
20 pts.

SQLRPGLE
How to delete all the records from file(bpro1) using sqlrpgle. Please provide all the steps to do.

Answer Question   |  August 4, 2008  1:13 PM
SQLRPGLE
asked by:
35 pts.

AS/400 and Oracle Access Manager
I have a strange behavior in an SQLRPGLE program accessing iSeries DB2 and Oracle via Oracle Access Manager. The program is very simple and reads values from two Oracle Tables in this way : a. SELECT …. into ….. FROM Table1 WHERE ….. return OK : 1 row as expected with my two fields filled. [...]

Answer Question   |  April 22, 2010  3:58 PM
AS/400, DB2, iSeries DB2, Oracle Access Manager, RPGLE, SQL, SQLRPGLE
asked by:
30 pts.

Joining More Than 2 Files
What is the best way to join more than 2 files using SQLRPGLE with embedded sql?

Answer Question   |  April 22, 2010  1:59 PM
Embedded SQL, SQLRPGLE
asked by:
35 pts.

How to explicitely Lock a record of a file in a SQLRPGLE program using embeded SQLs?
How to explicitely Lock a record of a file in a SQLRPGLE program using embeded SQLs?

Answer Question   |  May 19, 2008  6:32 AM
Embedded SQL, Record lock, SQLRPGLE
asked by:
5 pts.