Well I am a little anoyed as I wanted to write a basic fit for my needs app basded on firebird as I remember a previous employer used interbase a lot but I am stuck making primary keys get values automatically. knowing we have some experts on this list please help
Owen
$isql-fb Use CONNECT or CREATE DATABASE to specify a database SQL> CREATE DATABASE '/tmp/dvb4.fdb'; SQL> CREATE TABLE TABLEA ( CON> TABLEAPK BIGINT NOT NULL PRIMARY KEY , CON> TABLEANAME varchar(20) CON> ); SQL> COMMIT; SQL> CREATE GENERATOR GENPKTABLEA; SQL> COMMIT; SQL> CREATE TRIGGER BEFOREINSERTTABLEA for TABLEA CON> ACTIVE BEFORE INSERT position 0 CON> AS CON> BEGIN CON> IF(NEW.TABLEAPK IS NULL) THEN CON> NEW.TABLEAPK = GEN_ID(GENPKTABLEA, 1); Statement failed, SQLCODE = -104
Dynamic SQL Error -SQL error code = -104 -Unexpected end of command SQL> END CON>