SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


Converting BLOB to different datatypes


Converting BLOB to different datatypes

Author
Message
VastSQL
VastSQL
SSCrazy Eights
SSCrazy Eights (9.9K reputation)SSCrazy Eights (9.9K reputation)SSCrazy Eights (9.9K reputation)SSCrazy Eights (9.9K reputation)SSCrazy Eights (9.9K reputation)SSCrazy Eights (9.9K reputation)SSCrazy Eights (9.9K reputation)SSCrazy Eights (9.9K reputation)

Group: General Forum Members
Points: 9882 Visits: 5312
Hi Experts,

Is it possible to convert a java object which is now stored as a BLOB field to character values.
The java object in BLOB contains parent and child values ,we need to differentiate those.The blob value contains
some numbers, some charcters, some object itself this level of child objects may be more than 4-5 level

Is it possible and if yes then how?

Thanks in Advance.
Orlando Colamatteo
Orlando Colamatteo
SSC-Forever
SSC-Forever (41K reputation)SSC-Forever (41K reputation)SSC-Forever (41K reputation)SSC-Forever (41K reputation)SSC-Forever (41K reputation)SSC-Forever (41K reputation)SSC-Forever (41K reputation)SSC-Forever (41K reputation)

Group: General Forum Members
Points: 41652 Visits: 14413
Not unless you can deserialize the object using a SQLCLR object to review its properties, which I highly doubt. There is no native Java capability in SQL Server that would allow you to inspect that BLOB inside the database as if it were an object again, that I know of. You might be able to shoehorn the instantiation of a Java object into the scope of a SQLCLR object somehow by making an external call. Maybe you could have a SQLCLR object pass the BLOB to an external web service or executable for deserialization and inspection, but that would be terribly slow I would venture, if its even technically feasible. What you might want to start doing is storing the parent-child indicators in a separate column(s) next to the BLOB but you still have the problem of inspecting the existing data to initialize the new column(s).

__________________________________________________________________________________________________
There are no special teachers of virtue, because virtue is taught by the whole community. --Plato
VastSQL
VastSQL
SSCrazy Eights
SSCrazy Eights (9.9K reputation)SSCrazy Eights (9.9K reputation)SSCrazy Eights (9.9K reputation)SSCrazy Eights (9.9K reputation)SSCrazy Eights (9.9K reputation)SSCrazy Eights (9.9K reputation)SSCrazy Eights (9.9K reputation)SSCrazy Eights (9.9K reputation)

Group: General Forum Members
Points: 9882 Visits: 5312
Thanks OPC
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search