Ask Your Question
0

Cannot save Base Table - firebird_sdbc error

asked 2019-10-27 10:24:22 +0200

Ubiquity gravatar image

LO 6.3 - attempting to save a simple table from design view I get the following errors: SQL Status: S1000

Error while saving the table design

Error code: 1

firebird_sdbc error: *unsuccessful metadata update *CREATE TABLE AssetDetail failed *Identity column AssetID of table AssetDetail must be of exact number type with zero scale caused by 'CREATE TABLE "AssetDetail" ("AssetID" NUMERIC(15,1) GENERATED BY DEFAULT AS IDENTITY,"Description" VARCHAR(100) NOT NULL,"MakeID" INTEGER NOT NULL,"Model" VARCHAR(100),"Serial_Number" VARCHAR(100),"VendorID" INTEGER NOT NULL,"AcquisitionValue" DECIMAL(15,2) NOT NULL,"DateAcquired" DATE NOT NULL,"Warranty" INTEGER NOT NULL,"ReplacementCost" DECIMAL(15,2) NOT NULL,"DateDisposed" DATE,"DisposalPrice" DECIMAL(15,2) NOT NULL,"LocationID" INTEGER NOT NULL,"CategoryID" INTEGER NOT NULL,"TypeID" INTEGER NOT NULL,"Donated" BOOLEAN NOT NULL,"LoanStatus" BOOLEAN NOT NULL,"StatusID" INTEGER NOT NULL,"DepreciableLife" INTEGER,"DepreciationMethod" CHAR(2) NOT NULL,"TagID" INTEGER NOT NULL,"TagDate" DATE,"TagExpiry" DATE,"Comments" VARCHAR(32765),"Picture" BLOB, PRIMARY KEY ("AssetID"))'

I did try Integer, BigInteger and Small Integer which all give similar errors - this time starting with: Error code: 1

firebird_sdbc error: *unsuccessful metadata update *CREATE TABLE AssetDetail failed *Dynamic SQL Error *SQL error code = -204 *Data type unknown *Implementation limit exceeded *COLUMN <missing arg="" #1="" -="" possibly="" status="" vector="" overflow=""> caused by

While I could return to building this database with embedded HSQLDB it seemed appropriate to embrace Firebird but it is a bit discouraging to encounter such an error effectively at the outset.

edit retag flag offensive close merge delete

1 Answer

Sort by » oldest newest most voted
0

answered 2019-10-27 21:19:15 +0200

Ratslinger gravatar image

Hello,

There are certainly problems remaining with Firebird embedded DB. Have had few problems with the server version. Personally use PostgreSQL but still mix in HSQLDB and Firebird embedded especially for portability and posting here.

For your situation, don't understand why you were defining a primary key with a NUMERIC(15,1). NUMERIC(15) will work but typically this is an INTEGER type. The second problem deals with the size of the record. "Comments" VARCHAR(32765) is the problem. See answers in this post -> LO Database newbie - Firebird error trying to create new project. Changing this to a BLOB type field, along with changing the primary key field, allows the creation of the table.

edit flag offensive delete link more

Comments

Thanks Ratslinger - will try these changes. I would normally have used INTEGER but cannot now re-find where NUMERIC was recommended. I will also try it with a reduction in the size of the VARCHAR for Comments as the actual size will never exceed a few hundred characters.

Ubiquity gravatar imageUbiquity ( 2019-10-28 03:23:34 +0200 )edit
Login/Signup to Answer

Question Tools

1 follower

Stats

Asked: 2019-10-27 10:24:22 +0200

Seen: 339 times

Last updated: Oct 27 '19