post Image to sybase using storedproc&Delphi

Sybase's storedproc seems haven't image type parameter.
Who can give me a suggestion or example that can post image to sybase using storedproc&delphi.
in delphi:
buffer is a point to a image
storedproc1.ParamByName('ImageType').SetBlobData(buffer, sizeof(buffer));
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

An image datatype can't be used as a parameter in a stored proc.

What you can do is store the image in a table and pass the table's primary key to the procedure.


Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
tiger2000Author Commented:
Hi, levine
Please give me a detail sulotion.
can you send me a example?

I'm puzzled for a long time.

Thx in advance!
What you could do is create another table that's only purpose is to hold your image object temporarily.

From your application, you would load this image into the table along with setting some identifier in another column in this "temporary" table.

Then you would call your stored procedure and pass as one of the parameters to the stored procedure, the identifier for your image record. The stored proc would then retrieve the image from the "temporary" table, use it in your stored proc and if all was successful, you would then delete it from the "temporary" table.

This gets around the issue of actually passing the image object to a stored procedure. You just pass the identifier for the image object you loaded in your other table.

It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Sybase Database

From novice to tech pro — start learning today.