Re: EOModeler NSData and varbinary save error

Ray Kiddy <[email protected]> Wed, 7 Apr 2004 17:53:15 -0700
Newsgroups gmane.comp.web.webobjects.eof
Message-ID <[email protected]>
There are many subtle combinations of column types in the database and  
Value Class settings in the model which may be causing you problems.  
The answer is almost certain to be that you need to set the Value Type  
to something. To see what values are possible, go to:

http://developer.apple.com/documentation/WebObjects/UsingEOModeler/ 
4WorkingWithAttributes/chapter_4_section_3.html#//apple_ref/doc/uid/ 
TP30001018-DontLinkChapterID_3-BABBEBAI

You can also get here through:

ADC Home > Reference Library > Documentation > WebObjects > Tools >  
Using EOModeler > Working With Attributes > More About Attribute  
Characteristics

- ray

On Apr 7, 2004, at 2:26 PM, Ty Shipman, CIO/CTO, Kagi wrote:

>
> Fellow WOE users:
>
> So we are using Sybase and WOE 5.2 on Mac OS X 10.2.8 -- JDBC adaptor
>
> The code works in 4.5 WOE on NT -- C adaptor
>
> We are attempting to port it to 5.2
>
> I have a column in my database that is defined as varbinary(255), I  
> can select the data no problem in 5.2, but when I go to change it I  
> get the following error.
>
>
> Next exception:SQL State:42000 -- error code: 257 -- msg: Implicit  
> conversion from datatype 'IMAGE' to 'VARBINARY' is not allowed. Use  
> the CONVERT function to run this query.
>
> The column in EOModeler has the following definitions:
>
> Name:		vfield
> Value Class:	NSData
> Ext. Type:	varbinary
> Length:		255
> Value Type:	(blank)
> Value Class(java): NSData
> Nullable:	yes
>
> The "Value Type" is blank.  I have tried a few of the conversions that  
> I thought might make since, but nothing worked.  Is there a conversion  
> specifier to NSData (that is not documented) so it is converted to  
> binary and not IMAGE type when the save happens?  Or, do I have to  
> recode it somehow?
>
> I am not sure if this is a bug or user error on my part?
>
> Any help would be greatly appreciated.
>
> Regards
> ty
>
>
>
> -- 
> I am trying to become obsolete.   But I can not because I am  
> autodidactic.
>
> That is why I put lots of comments into the code, so I could forget.
> _______________________________________________
> EOF mailing list
> [email protected]
> http://www.omnigroup.com/mailman/listinfo/eof
>