Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Sql code: -922,MQ series

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DB2
View previous topic :: :: View next topic  
Author Message
Prem Prakash

New User


Joined: 07 Jan 2006
Posts: 6
Location: India

PostPosted: Mon Apr 10, 2006 3:34 pm    Post subject: Sql code: -922,MQ series
Reply with quote

Hi all,
I am creating a driver module for communication between fron end(VB) and Backend(Mainframe) using MQ series. i am new to MQ series. i am getting the data from front end in the input queue and storing those data in some temporary variables. uptill, its fine but when i am trying to insert those data in a table,its giving sql error -922. although, the table creator has given me all the acess on tables and also granted me bind and execute access on plan. Please help me out. Thanks.
Back to top
View user's profile Send private message

guptae

Moderator


Joined: 14 Oct 2005
Posts: 1187
Location: Bangalore,India

PostPosted: Mon Apr 10, 2006 6:11 pm    Post subject:
Reply with quote

Hi Prem Prakash,

Would u provide the code
Back to top
View user's profile Send private message
Prem Prakash

New User


Joined: 07 Jan 2006
Posts: 6
Location: India

PostPosted: Tue Apr 11, 2006 11:59 am    Post subject:
Reply with quote

Hi Ekta,
I am pasting below the code snippet where i am facing this problem:

****Getting the message from Input queue**********

CALL 'MQGET' USING W03-HCONN
W03-HOBJ-CHECKQ
MQMD
MQGMO
W03-BUFFLEN
W03-MSG-DATA
W03-DATALEN
W03-COMPCODE
W03-REASON.
*
IF (W03-COMPCODE NOT = MQCC-OK) OR
(W03-REASON = MQRC-NO-MSG-AVAILABLE)
MOVE 'MQGET*' TO M02-OPERATION
MOVE MQOD-OBJECTNAME TO M02-OBJECTNAME
PERFORM RECORD-CALL-ERROR
GO TO A-MAIN-EXIT
END-IF.
****Moving msgdata to working storage variable ******
MOVE W03-MSG-DATA TO W03-MAN1TEST-MSG

EXEC CICS WRITEQ TS
QUEUE('CSQ4SAMP')
FROM (W03-MAN1TEST-MSG)
LENGTH(W05-TS-MESSAGE-LENGTH)
END-EXEC.
******Moving the data into dclgen variables of table

MOVE W03-MAN1TEST-MSG TO ASPC-MSG
MOVE W03-MAN1TEST-MSG-REPLY TO ASPC-REPLY

******Inserting into table*************
****(Here i am getting SQL error -922)****

EXEC SQL
INSERT INTO g56715.DM_AISPOC_TBL
VALUES(:ASPC-MSG,:ASPC-REPLY)
END-EXEC
PERFORM SQLERROR-HANDLE-PARA.


Hope this code snippet is sufficient enough for you to get the reason of error. Thanks.
Back to top
View user's profile Send private message
martin9

Active User


Joined: 01 Mar 2006
Posts: 288
Location: Basel, Switzerland

PostPosted: Tue Apr 11, 2006 3:23 pm    Post subject:
Reply with quote

hy Prem Prakash,

your program is a cics program.
which transaction you need to run your program?
if trx is XYZ then you have a transaction entry in cics.
check: cemt i tran(XYZ)
if it is so, then note:
you also need a db2tran entry in cics and a db2entry entry,
which points to the db2 plan, thru which you can access the
data.
check: cemt i db2tran(XYZ), cemt i db2entry(XYZ)

i hope this will help you...

martin9
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DB2 All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Job failing with USER = 4093 REASON C... Pradeepa S ABENDS & Debugging 1 Wed May 17, 2017 3:35 pm
No new posts COBOL Code Parsers and Lineage Establ... balimanja COBOL Programming 2 Tue May 02, 2017 3:30 am
No new posts Cobol upgrade - source code missing f... gthmrj IBM Tools 1 Wed Apr 26, 2017 6:04 pm
No new posts JCL to Set Return code based on DB2 S... vinu78 DB2 17 Mon Mar 13, 2017 9:47 pm
No new posts IMS region inactive - User abend code... gthmrj IMS DB/DC 5 Tue Mar 07, 2017 12:29 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us