Column not found, message from server: "Unknown column 'type' in
'field list'"
You may get this error if you add a many-to-one relationship to a
class, and forget to add the corresponding column to the corresponding
table. For example, if you have a table like this:
create table cd (
id integer primary key,
title varchar(255)
);
and a class CD:
public class CD {
protected int id;
protected String title;
}
with a Hibernate mapping document:
then, if you add a property to the class and mapping document:
public class CD {
protected int id;
protected String title;
protected Colour colour;
}
then you will get an error message something like the above unless you
remember to add a column to the table cd:
create table cd (
id integer primary key,
title varchar(255),
colour_ref integer
);
create table colour (
id integer primary key,
name varchar(255)
);
"Collections may not contain other collections."
-- http://www.hibernate.org/hib_docs/reference/en/html/collections.html#collections-persistent