This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes JDBC and the fly likes Reading BLOB data in DB2 SQL Stored Procedure Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "Reading BLOB data in DB2 SQL Stored Procedure" Watch "Reading BLOB data in DB2 SQL Stored Procedure" New topic
Author

Reading BLOB data in DB2 SQL Stored Procedure

Keerthi M
Greenhorn

Joined: Sep 10, 2007
Posts: 4
First of all sorry if this is not the right forum for my question.



We are using DB2 v9.5 on Windows/AIX. We have a .txt file which has 100k's records in below format. The file is delimited by newline character as shown in below data format. We have a database column of type BLOB. In this database column we store the .txt file as BLOB data.


data format
---------------

T010 AZ00 0000031
0Z11 A701 0011001
...
...
...


I need to write a DB2 SQL Stored Procedure that reads this BLOB column and parses the individual records(ie. each record is on a newline) and insert in some other tables. Now, my question is how to write such DB2 SQL Stored Procedure to accomplish this.

I would appreciate if you can help me with code snippets, URLs etc.



Thanks & Regards,
Keerthi
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Reading BLOB data in DB2 SQL Stored Procedure
 
Similar Threads
A Java program or an ETL?
Inserting BLOB data
How to pass BLOB to a PL/SQL Stored Procedure
problem uploading file in oracle databse
Java Stored procedure