[jboss-user] [EJB 3.0] - Re: mapping problems between ntext, jtds and ejb3

leulberg do-not-reply at jboss.com
Fri Jul 14 15:23:12 EDT 2006


I tried useLOB=true in jtds and annotation like this


  | 	/**
  | 	 * TextArea message
  | 	 */
  | 	@Lob @Basic
  | 	@Column(name="message", columnDefinition="NTEXT NULL")
  | 	public void setMessage(String s){
  | 		this.message = s;
  | 	}
  | 	public String getMessage(){
  | 		return this.message;
  | 	}
  | 

But no better result.

In addition the stack trace:


  | org.hibernate.HibernateException: Wrong column type: message, expected: varchar(255)
  | 	at org.hibernate.mapping.Table.validateColumns(Table.java:251)
  | 	at org.hibernate.cfg.Configuration.validateSchema(Configuration.java:1002)
  | 	at org.hibernate.tool.hbm2ddl.SchemaValidator.validate(SchemaValidator.java:116)
  | 	at org.hibernate.impl.SessionFactoryImpl.<init>(SessionFactoryImpl.java:314)
  | 	at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1213)
  | 	at org.hibernate.ejb.Ejb3Configuration.buildEntityManagerFactory(Ejb3Configuration.java:631)
  | 	at org.hibernate.ejb.Ejb3Configuration.createEntityManagerFactory(Ejb3Configuration.java:760)
  | 	at org.hibernate.ejb.Ejb3Configuration.createEntityManagerFactory(Ejb3Configuration.java:627)
  | :
  | :
  | 


View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3958193#3958193

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3958193



More information about the jboss-user mailing list