Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion Groups
Database Servers
DB2InformixIngresMS SQLOraclePervasive.SQLPostgreSQLProgressSybase
Desktop Databases
FileMakerFoxProMS AccessParadox
General
General DB TopicsDatabase Theory
Related Topics
Java Development.NET DevelopmentVB DevelopmentMore Topics ...

Database Forum / DB2 Topics / March 2006

Tip: Looking for answers? Try searching our database.

jpg file to mainframe

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
ganapath - 27 Mar 2006 22:43 GMT
Hi,

i have a jpg file on my pc which contains only 1 photo,
1. i would like to ftp the file to mainframe and then
2. insert that value into blob field of a db2 table

can anyone tell me how to do above mentioned steps

Thanks
Phil Sherman - 28 Mar 2006 07:13 GMT
Assuming you are running ftp on the PC, the following commands (after
connecting to the mainframe) should move your file without destroying it:
image
put fileName

The image command tells ftp that you are sending binary data and ascii
(to ebcdic) translation should not take place. The put command sends the
file, keeping the existing file name. This works best if your file name
is compatible with your mainframe naming conventions.

The easiest way to load the file is to use ISPF to build a file
containing one record that corresponds to the row data associated with
the image. The record will contain a file reference pointing to the
image file. The DB2 utilities reference (LOAD command) should explain
how to build the file reference data for the blob column.

Philip Sherman

> Hi,
>
[quoted text clipped - 5 lines]
>
> Thanks
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2009 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.