View previous topic :: View next topic
|
Author |
Message |
lanand_hps
New User
Joined: 05 Dec 2007 Posts: 82 Location: chennai
|
|
|
|
Hi,
Can we use COBOL local arrays in DB2 queries in the application program?
EXEC SQL
SELECT * FROM TABLE
WHERE FIELD = :WS-EMPLOYEE (WS-INDEX)
END-EXEC.
The above query is giving me errors....
Can't we not use arrays inside embedded SQL?
Thannks. |
|
Back to top |
|
|
Craq Giegerich
Senior Member
Joined: 19 May 2007 Posts: 1512 Location: Virginia, USA
|
|
|
|
lanand_hps wrote: |
Hi,
Can we use COBOL local arrays in DB2 queries in the application program?
EXEC SQL
SELECT * FROM TABLE
WHERE FIELD = :WS-EMPLOYEE (WS-INDEX)
END-EXEC.
The above query is giving me errors....
Can't we not use arrays inside embedded SQL?
Thannks. |
This straight from the Application Programming & SQL Guide
"You cannot define host variables, other than indicator variables, as arrays. You can specify OCCURS only when defining an indicator structure. You cannot specify OCCURS for any other type of host variable.". |
|
Back to top |
|
|
lanand_hps
New User
Joined: 05 Dec 2007 Posts: 82 Location: chennai
|
|
|
|
thanks.. |
|
Back to top |
|
|
|