View previous topic :: View next topic
|
Author |
Message |
sushanth bobby
Senior Member
Joined: 29 Jul 2008 Posts: 1020 Location: India
|
|
|
|
Hello,
I want to know, how to insert a picture into a DB2 Table.
My table structure will be like this
Code: |
ID VARCHAR(10),
NAME VARCHAR(10),
Description VARCHAR(255),
IMAGE CLOB(2 M) |
The picture, that i want to insert is in desktop - currently.
1. Say i will upload the picture into mainframe in binary format.
Question: Uploading the picture in binary format is correct or wrong ?
2. HOW to INSERT the picture into the DB2 TABLE ?
I am clueless about this..........
I refered to this post, But I'm not using any programs for insertion. Just plain INSERT STATEMENT.
ibmmainframes.com/viewtopic.php?t=36854&highlight=insert+lob
Thank You,
Sushanth Bobby |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
Suggest you use a program for these inserts. . . |
|
Back to top |
|
|
vasanthz
Global Moderator
Joined: 28 Aug 2007 Posts: 1742 Location: Tirupur, India
|
|
|
|
Quote: |
1. Say i will upload the picture into mainframe in binary format.
Question: Uploading the picture in binary format is correct or wrong ? |
I was trying to send pictures via SMTP and came across this scenario.
Transferring to mainframes using binary format is the correct way.
If you want to verify, then u can re-tranfer the picture back from mainframes to PC and open the file. It would be proper.
It once tried with PS file with recfm = fb and rec length = 80 and it worked fine. |
|
Back to top |
|
|
sushanth bobby
Senior Member
Joined: 29 Jul 2008 Posts: 1020 Location: India
|
|
|
|
Yes & Thank You Vasanth.
Since that happen to be the only way to send picture into mainframe.
Sushanth |
|
Back to top |
|
|
|