CREATE TABLE sentient_lists (
	sentient_link_id int NOT NULL,
	link_flags smallint NOT NULL,
	url varchar (255) NULL,
	edit_url varchar (255) NULL, 

	CONSTRAINT PK_sentient_lists PRIMARY KEY
	(
		sentient_link_id
	),
	CONSTRAINT FK_sentient_lists_to_resources FOREIGN KEY
	(
		sentient_link_id
	) REFERENCES resources (
		resource_id
	)
)
GO 

INSERT INTO classes (type, super_type, db_name, table_name, java_class)
	VALUES(99, 10, null, 'sentient_lists', 'org.bodington.server.resources.SentientLink')
GO

INSERT INTO fields (type, sequence, field, set_method_name, get_method_name, set_java_class, get_java_class, flags, foreign_type, set_method_name_foreign, get_method_name_foreign )
	VALUES(99, 1, 'sentient_link_id', 'setSentientLinkId', 'getSentientLinkId', 'org.bodington.database.PrimaryKey', 'org.bodington.database.PrimaryKey', 1, null, null, null );
GO

INSERT INTO fields (type, sequence, field, set_method_name, get_method_name, set_java_class, get_java_class, flags, foreign_type, set_method_name_foreign, get_method_name_foreign )
	VALUES(99, 2, 'link_flags', 'setLinkFlags', 'getLinkFlags', 'byte', 'byte', 0, null, null, null );
GO

INSERT INTO fields (type, sequence, field, set_method_name, get_method_name, set_java_class, get_java_class, flags, foreign_type, set_method_name_foreign, get_method_name_foreign )
	VALUES(99, 3, 'url', 'setUrl', 'getUrl', 'java.lang.String', 'java.lang.String', 0, null, null, null );
GO

INSERT INTO fields (type, sequence, field, set_method_name, get_method_name, set_java_class, get_java_class, flags, foreign_type, set_method_name_foreign, get_method_name_foreign )
	VALUES(99, 4, 'edit_url', 'setEditUrl', 'getEditUrl', 'java.lang.String', 'java.lang.String', 0, null, null, null );
GO

