Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 Transact-SQL (2000)
 Problem with IMAGE field

Author  Topic 

polynominal
Starting Member

2 Posts

Posted - 2006-02-20 : 06:57:44
At work we have an online form on the firms website, with allows applicants to apply for jobs. The applicant is also allowed to attach a CV (must be in rtf format) to his/her application.

The CV is stored in a sql database as an image type, length 16.

If I do SELECT {fieldname} I get

fieldname
<binary>
<binary>

I have a reporting package that needs to read and interpret the field, but cannot do so in its present state.

I have tried Select CAST(CAST({fieldname} as varbinary(8000)) As varchar(8000))

This conerts it to rtf format as follows

<rtf1 etc

This works fine for CV's under 8000, but I have many over.

My question is, is there a way I can interpret CV's over 8000 or is there another way of doing this

Thanks

Poly








Kristen
Test

22859 Posts

Posted - 2006-02-20 : 07:35:35
If its RTF then I think all the characters will be ASCII (32 to 127) and no control/weird characters

If that's the case then perhaps you should change the definition of the column from IMAGE (essentially "binary") to TEXT.

Kristen
Go to Top of Page

polynominal
Starting Member

2 Posts

Posted - 2006-02-21 : 02:50:50
Thanks for the reply.

Unfortunately the database guys will not change the field to a text field. so I need an alternative solution
Go to Top of Page

madhivanan
Premature Yak Congratulator

22864 Posts

Posted - 2006-02-21 : 03:21:13
See if this helps
http://www.microsoft.com/technet/prodtechnol/sql/2000/reskit/part3/c1161.mspx

Madhivanan

Failing to plan is Planning to fail
Go to Top of Page

Kristen
Test

22859 Posts

Posted - 2006-02-21 : 08:04:40
"Unfortunately the database guys will not change the field to a text field"

That's just daft! - assuming this column isn't also needed to store pure-binary, of course!

Kristen
Go to Top of Page

jen
Master Smack Fu Yak Hacker

4110 Posts

Posted - 2006-02-22 : 03:52:45
can you save the resumes as files and save the path in the field?

just wondering...

--------------------
keeping it simple...
Go to Top of Page
   

- Advertisement -