MySQL Script Generation for UNIQUE CONSTRAINT

Posts   
 
    
ab-tools
User
Posts: 15
Joined: 18-Dec-2020
# Posted on: 23-Dec-2020 19:50:37   

Hello,

when generating a DB create script for MySQL a unique constraint is added like this:

ALTER TABLE `TestTable`
    ADD CONSTRAINT "UC_52d91574da6a22462caae7fdc26" UNIQUE
    (
        `TestField` 
    );

Trying to execute this SQL statement will lead to a syntax error as the quote character is not supported, I manually need to change " to ` first.

Best regards Andreas

Otis avatar
Otis
LLBLGen Pro Team
Posts: 39612
Joined: 17-Aug-2003
# Posted on: 24-Dec-2020 09:06:48   

Bug, we'll fix that.

Frans Bouma | Lead developer LLBLGen Pro
Otis avatar
Otis
LLBLGen Pro Team
Posts: 39612
Joined: 17-Aug-2003
# Posted on: 24-Dec-2020 10:15:22   

Please see the 5.6.6 and 5.7.3 hotfix builds on the website (My Account -> Downloads).

Frans Bouma | Lead developer LLBLGen Pro
ab-tools
User
Posts: 15
Joined: 18-Dec-2020
# Posted on: 24-Dec-2020 10:24:54   

Thanks, Frans, that was a quick fix - much appreciated! :-)

But I think I don't have an account on your website (besides in the forum here) yet as I'm still in the 30 days trial: Can I still get the hotfix somewhere?

Best regards and thanks again Andreas

Otis avatar
Otis
LLBLGen Pro Team
Posts: 39612
Joined: 17-Aug-2003
# Posted on: 24-Dec-2020 23:46:05   

ab-tools wrote:

Thanks, Frans, that was a quick fix - much appreciated! :-)

But I think I don't have an account on your website (besides in the forum here) yet as I'm still in the 30 days trial: Can I still get the hotfix somewhere?

Best regards and thanks again Andreas

No, sorry. You then have to alter the template yourself (DDL SQL templates -> mysql specific)

Frans Bouma | Lead developer LLBLGen Pro
ab-tools
User
Posts: 15
Joined: 18-Dec-2020
# Posted on: 25-Dec-2020 10:12:08   

No problem, thanks, was easy to find were - just fixed that myself in the template!