A BLOB field usually contains (large) amounts of binary data, so there is no easy way to view the "actual" text inside of the blob unless you know what is meant to be in there and how it was encoded.
For instance, if it was an image you could send it to the browser with the correct headers. If it was a PDF, you could send it to the browser with PDF headers.
If you mean RTF text as in a RTF file, you could send it to the browser with the correct headers to force it to be downloaded with a .RTF extension and view it from there. If the file isn't corrupted and is an RTF, you could potentially use an RTF PHP class (assuming your using PHP, otherwise use whatever language you are using) to convert the raw data into the actual text.
Best I can tell...this is simply text with formatting (RTF?) stored as a blob. There are no pictures / files...users type into this little notes box from within the program, and thats it. There is no file saving or anything like that. At least as far as I can tell.
This is a third party app with a firebird backend database. Well over 100 tables which I've been digging through trying to get this little web page written ...
To be honest, there isn't alot of provided information apart from the database type; the application that enters that information into the database is also important; but I don't have a lot of experience with Firebird though less with "crystal reports" - which I am unfamiliar with.
Yeah..I wish I could get more information...but the company that develops this software isn't exactly thrilled to tell me how they encoded these "notes". All I know is that it there is not an actual file that gets saved with the field.
If I do a sql query to select the notes field, the output is:
Something similar to that...I have a feeling I'm going to have to play around with this quite a bit. I'm going to give the algorithm thing a shot on Monday.
Alright..still needing a little bit of help if anyone can help me out here.
Not so sure the data is Binary..
Here is an example output of doing a select statement on the blob field.
That's the result of a SELECT statement on the Blob field...
Obviously, the other rows of that query are similar..just with different fields.
I'm pretty sure that the blob field is stored as RTF...but if it was, then from what people have been telling me, I should see all the RTF markup when doing a select statement on that field.
Still having a hard time getting this company to tell me anything..anyone have any guesses as to how to display this data? All I know is it is stored for sure as a formatted text as when it is displayed in this program, it maintains spaces / tabs / indentions etc etc..
Doesn't look like you can sort based on the text contents of the blob field in MySQL. You'll have to pull them out and decode each field to sort them. Alternatively, if you control how the data goes in, you could do simultaneous writes to a separate MyISAM table that shares a primary key with the BLOB table. Then, in the new table, on insert, you could strip out the RTF encoding and store just the text. This will allow you a lot of possibilities such as sorting and performing Full-Text searches.
SELECT col_blob FROM table_blob, table_text WHERE table_blob.key=table_text.key ORDER BY table_text.col_text