Currently, I am using standalone GUI tool DbSchema to design my database schema.
I like it because it can
- Generate SQL code.
- Have graphing view on my entire database schema.
However, I realize the SQL code generate by DbSchema is not being recognized by PostgreSQL.
CREATE TABLE lot (
lot_id serial AUTO_INCREMENT NOT NULL,
operator_name text,
machine_name text,
timestamp timestamp,
CONSTRAINT pk_lot_id PRIMARY KEY(lot_id))
CREATE TABLE unit (
unit_id serial AUTO_INCREMENT NOT NULL,
fk_lot_id serial NOT NULL,
CONSTRAINT pk_unit_id PRIMARY KEY(unit_id),
CONSTRAINT fk_lot_id FOREIGN KEY( fk_lot_id ) REFERENCES lot ( lot_id ))
I get the error :
org.postgresql.util.PSQLException: ERROR: syntax error at or near "AUTO_INCREMENT"
Is there any alternative "just work" free tool that I can work with PostgreSQL, by providing above 2 features?