Solved

Convert OLE BLOB data type back to original BLOB

Posted on 2004-04-12
5
1,784 Views
Last Modified: 2013-12-26
Hi all,

  I have a problem here.  My senior was using a program to update some images (JPEG) file into Oracle database table as BLOB data type.  According to him, he was using OLE which cause a problem in reading it now.  He said that is because when we use OLE , the OLE will add extra information/codes in front and at the back of the BLOB.  That's why when we try to convert it back to original BLOB, problem occured.

  My question is, what is the easiest way to convert BLOB data in my table back to original BLOB data by removing that piece of codes from the BLOB.

  Please provide me the source code.  Thanks first for your help.

Regards,
Yong Yih
0
Comment
Question by:yongyih
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
5 Comments
 
LVL 2

Author Comment

by:yongyih
ID: 10806408
For your information, He is using PowerBuilder 7 to do it and I am using PowerBuilder 8 now.

I just want to write a program to loop through all the records in that table and convert all the BLOB data.

thanks.
0
 
LVL 15

Accepted Solution

by:
namasi_navaretnam earned 50 total points
ID: 10809070
Yong,

Have you read this doc yet ?

You can use selectblob, updateblob functions.

All info you need in outlined in thid doc
http://www.sybase.com/detail?id=44008

regards-
0
 
LVL 2

Author Comment

by:yongyih
ID: 10809719
hi namasi navaretname

  I know how to use selectblob and update blob.  I need to know the function that I can use to remove the extra bits in OLE BLOB for those photos that have been updated to database as OLE BLOB.

  Do you know how many byte of data will be add to original BLOB when we use OLE BLOB?

  Any idea?

regards,
Yong Yih
0
 
LVL 14

Expert Comment

by:sandeep_patel
ID: 10811394
hi,
as i know it is not adding any extra bytes...b'coz in my application i can store data from ole blob to database and again can read that data from database and assign to ole blob....i m not facing any problem....

as u said u r facing problem in selecting the data and assigned back to the database is it right ? if it's happening than can u describe what's the problem or error u r facing while selecting or assigning ?

if u don't know than...to show the image again no need to select from database and assign to OLE...simply u can create the datawindow and select the database blob column and directly display the contents....

just clearify your exact requirements....

regards,
sandeep
0
 
LVL 2

Author Comment

by:yongyih
ID: 10814353
Hi,

  I also not sure how does my senior program update those photos to database.  According to him, extra bit appear does exist in blob data stored in database.

  Create a datawindow to display the blob data is not possible I think because we are using different framework which is created by my company.

  If you update the data using OLE BLOB, can other application access those information?

Regards,
Yong Yih.
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Update (December 2011): Since this article was published, the things have changed for good for Android native developers. The Sequoyah Project (http://www.eclipse.org/sequoyah/) automates most of the tasks discussed in this article. You can even fin…
Jaspersoft Studio is a plugin for Eclipse that lets you create reports from a datasource.  In this article, we'll go over creating a report from a default template and setting up a datasource that connects to your database.
This tutorial covers a step-by-step guide to install VisualVM launcher in eclipse.
The viewer will learn how to use and create keystrokes in Netbeans IDE 8.0 for Windows.

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question