Hi,
First I would like to say that LLBLGen Pro is a great piece of work and most things are working excellent!
But I just ran into a problem when I was trying to create SQL DDL.
I have created a SQL DDL in a test project for Firebird but it didn't work in Flamerobin. I found out that these bugs are in the generated script:
In the primary keys section the name of the primary key is always followed by a double quote:
ALTER TABLE AccessRight
ADD CONSTRAINT PK_0d7ded84cbc9e7abcb8c77ee592" PRIMARY KEY
(
Id
);
I added a field of the type "System.byte[]" which resulted in a BLOB SUBTYPE 0. But SUBTYPE ist misspelled, it must be SUB_TYPE:
CREATE TABLE DocRevisions
(
Revision Integer NOT NULL,
DocumentId Integer NOT NULL,
UserId Integer NOT NULL,
Data BLOB SUBTYPE 0 NOT NULL,
Modification Date NOT NULL,
Checksum VARCHAR(150) NOT NULL
);
I have called an entity "User". A table "User" was automatically mapped but USER is a reserved word in firebird so the sql didn't run.
The produced sql file has UTF-8 coding. When you open the file with Flamerobin directly you'll get the UTF-8 identification bytes in the first line.
I have solved these problems by manipulating the file manually, changing the table name from "User" to "AppUser" and changing the coding of the sql file from UTF-8 to Ansi. After these modification the script ran through without errors.
I would suggest to always use quotations with names to avoid the problem with reserved words. The only disadvantage would be that the names are case sensitive then.
I also seems that in update scripts no primary key an foreign key informations are created. After adding a table I just got the CREATE TABLE statements but no ALTER TABLE with ADD CONSTRAINT.
Many thanks in advance for your help!
Best Regards,
Andreas