These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 posts ] 
Author Message
 Post subject: SchemaExport/BinaryBlob/MSSQL2005
PostPosted: Sun Nov 16, 2008 7:48 pm 
Newbie

Joined: Sun Nov 16, 2008 7:42 pm
Posts: 2
Hi we're using NH2.0 and MSSQL 2005 and using SchemaExport to generate out DB creation scripts.

One column contains image data and is defined as:

<property name="ImageData" column="ImageData" type="BinaryBlob">

The resulting SQL is generated as:

ImageData VARBINARY(8000) null,


Instead of VARBINARY(MAX) as I'd expect. Nothing I do to the xml seems to affect how the sql type is generated.

Any ideas? Thanks


Top
 Profile  
 
 Post subject:
PostPosted: Mon Nov 17, 2008 3:43 am 
Expert
Expert

Joined: Thu Dec 14, 2006 5:57 am
Posts: 1185
Location: Zurich, Switzerland
Have you tried adding sql-type="VARBINARY(MAX)" ?

_________________
--Wolfgang


Top
 Profile  
 
 Post subject:
PostPosted: Tue Nov 18, 2008 7:37 pm 
Newbie

Joined: Sun Nov 16, 2008 7:42 pm
Posts: 2
Tried that and it didn't work.
Had to specify length=2147383647 which seems redundant on a BinaryBlob, it seems like a bug in schemaexport that it's not mapping BinaryBlob to the correct length varbinary


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.