Re: AW: [Objectbridge-developers] generating mapping files and databa ses
Brought to you by:
thma
From: Ivan T. <to...@cr...> - 2001-08-23 13:23:25
|
On Thu, 2001-08-23 at 13:08, Mahler Thomas wrote: > 2. This has already been done by Ivan Toshkov. Just extract the attached zip > file into the ojb src directory. > Now you can use java ojb.broker.metadata repository.xml to generate the DDL > !!! Unfortunately, there isn't quite enough data in the repository.xml file to generate the correct SQL statements. So far, I don't know when to generate 'NOT NULL' and the size of VARCHAR objects. So, perhaps we should add this data to the XML? (While on the subject, the repository.xml looks somewhat strange, because of the lack of naming convention. E.g. elements like FieldDescriptor, field.name and jdbc_type. I would personally like to see some of the fields, as attributes. For example, PrimaryKey could be an attribute to FieldDescriptor. This can be used to set a meeningfull default value in the DTD.) The second issue is with different syntax for the different DBMSes. IMO, the best way to do that is to support some kind of pluggable SQL generators, and I'll try to spend some time on this during the weekend (no promises, though :)). Cheers, Ivan |