View previous topic :: View next topic
|
Author |
Message |
Rajen
New User
Joined: 05 May 2005 Posts: 61
|
|
|
|
Hi Can anyone please tell me how can i insert Long string through JCL SYSTSIN parameter.
I have to insert a long error message in DB2 table.
Example query is given below.
INSERT INTO table
error_message
VALUES ( 'please enter date...(some big message) in valid format -- yyyy/mm/yy')
Now the problem with this message is, it is going beyong 72th (even 80th) column and i need to continue this error message in the next line.
Can anyone tell me how to give continuation in SYSTSIN in JCL?
I tried with continuation at 72th column but its abending giving message like ' Passing string too long' |
|
Back to top |
|
|
priyesh.agrawal
Senior Member
Joined: 28 Mar 2005 Posts: 1448 Location: Chicago, IL
|
|
|
|
Try like this... putting a plus sign at last for continuation...
Code: |
INSERT INTO table
error_message
VALUES ( 'please enter date...(some big message) in +
valid format -- yyyy/mm/yy') |
|
|
Back to top |
|
|
Rajen
New User
Joined: 05 May 2005 Posts: 61
|
|
|
|
Hi Priyesh,
Thanks A lot for reply.
Can you please tell me where should i place that plus '+' sign.
I think it should be at 72th column but just to make sure i am asking.
Thanks,
Rajen. |
|
Back to top |
|
|
Kevin
Active User
Joined: 25 Aug 2005 Posts: 234
|
|
|
|
You could also just make the dataset's LRECL larger, so that you might be able to fit the data on one record.
Just a thought. |
|
Back to top |
|
|
priyesh.agrawal
Senior Member
Joined: 28 Mar 2005 Posts: 1448 Location: Chicago, IL
|
|
|
|
Do you really need a continuation. Below query works just fine for me.
Code: |
=COLS> ----+----1----+----2----+----3----+----4----+----5----+----6----+----7--
****** ***************************** Top of Data ******************************
000010 INSERT INTO CREATOR.TABLE_NAME
000012 VALUES ('PRIYESH TST',1,'THIS IS A TEST RECORD PLEASE IGNORE THE SAME
000013 , DONT CONSIDER'); |
|
|
Back to top |
|
|
Rajen
New User
Joined: 05 May 2005 Posts: 61
|
|
|
|
Hi Priyesh,
Thanks again for reply.
I guess u have used comma (,) on 7th or 8th charactor. Earlier i mentioned about that continuation charactor. |
|
Back to top |
|
|
priyesh.agrawal
Senior Member
Joined: 28 Mar 2005 Posts: 1448 Location: Chicago, IL
|
|
|
|
Hi Rajen,
That comma (",") is a part of my string to be loaded onto Table, not a continuation character. Thus my field value after upload would looks like below.
Code: |
THIS IS A TEST RECORD PLEASE IGNORE THE SAME , DONT CONSIDER |
|
|
Back to top |
|
|
|