Solved

Convert OLE BLOB data type back to original BLOB

Posted on 2004-04-12
5
1,766 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
  • 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

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
eclipse find/step into stored procedure 3 178
dangers of teaching programming 10 126
What is the best editor for PowerShell scripts? 7 89
Online file editor, manager 6 62
Here is a helpful source code for C++ Builder programmers that allows you to manage and manipulate HTML content from C++ code, while also handling HTML events like onclick, onmouseover, ... Some objects defined and used in this source include: …
How to install Selenium IDE and loops for quick automated testing. Get Selenium IDE from http://seleniumhq.org Go to that link and select download selenium in the right hand columnThat will then direct you to their download page.From that page s…
THe viewer will learn how to use NetBeans IDE 8.0 for Windows to perform CRUD operations on a MySql database.
The viewer will learn how to use and create keystrokes in Netbeans IDE 8.0 for Windows.

920 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

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now