-->
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.  [ 2 posts ] 
Author Message
 Post subject: Blob defaults in MySQL tinyblob - how to make that longblob?
PostPosted: Sun Nov 13, 2005 4:27 am 
Newbie

Joined: Sun Nov 13, 2005 3:51 am
Posts: 1
Hi,

I am using:

JBoss 4.0.3 SP1 with the EJB3 features and MySQL.

I have a simple Entity EJB and created the following Blob attribute:

@Entity
public class File implements Serializable{

private int id;
private String fileName;
private String contentType;
private int fileSize;
private Blob file;

@Lob(fetch=FetchType.EAGER)
public Blob getFile() {
return file;
}
public void setFile(Blob file) {
this.file = file;
}
[..]
}

This works fine, but I can only store very small files as the MySQL coloumn which is dynamically created is 'tinyblob'.

How can I change this to 'longblob' which can take larger files?

Thanks.

Stefan


Top
 Profile  
 
 Post subject:
PostPosted: Sun Nov 13, 2005 5:17 am 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 12:50 pm
Posts: 5130
Location: Melbourne, Australia
@Column(length=...)


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 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.