Re: BLOB Datatype question ?
Posted in 1997
Sudhir Nair wrote: >Does anybody know of a built in function or have written a function to >find out the content of a byte column. I have a byte column that could >hold either text or binary data (like voice, picture,etc). Is there a >way to find out if the data in that column is a text or binary(picture, >voice,etc). > >I have a situation here where an application stores a value which is an >alert into a column. This alert could be a memo text, it could be >voice, it could be even a picture. Hence I store this input to a byte >column. Now there is a second program that has to check this column and >find out if the content is a memo, voice, etc and do an appropriate >action. > >Does anyone have any suggestions, Please forward it to >sudhirn@fourgen.com Sudhir, I just had a similar situation to a small extent: The data could be GIF or JPG. What to do? I copped out by retrieving the blob data into a file and running NetScape against it. This should cover a broad range of multi-media data types. The real solution is to store the data type in a column of the table and an internal table (another database table?) to define what actions to take depending on the datatype of the blob data for that row. -- -- Jake (Lost in thought and won't ask for directions) . . _..-'( )`-.._ ./'. '||\\\\. }\\_/{ .//||` .`\\. ./'.|'.'||||\\\\|.. )o o( ..|//||||`.`|.`\\. ./'..|'.|| |||||\\`````` \\,@,/ ''''''/||||| ||.`|..`\\. ./'.||'.|||| ||||||||||||. ||| .|||||||||||| ||||.`||.`\\. /'|||'.|||||| ||||||||||||{ | }|||||||||||| ||||||.`|||`\\ '.|||'.||||||| ||||||||||||{ | }|||||||||||| |||||||.`|||.` '.||| ||||||||| |/' ``\\||`` | ''||/'' `\\| ||||||||| |||.` |/' \\./' `\\./ \\!|\\ /|!/ \\./' `\\./ `\\| V V V }' `\\ /' `{ V V V \\ \\ \\ V / / / +-----------------------------------------------------------+ | Impeccable Logic: A thought process which successfully | | resists chicken bites | +-----------------------------------------------------------+