Subject | Computed column for primary key |
---|---|
Author | firebirdsql |
Post date | 2011-06-08T23:14:18Z |
CREATE TABLE accounts
(
dept_id INT,
build_id INT,
account_nbr COMPUTED BY (dept_id || '-' || build_id),
PRIMARY KEY(account_nbr)
);
It complains that I cannot use an computed column for the index. How would I fix this?
Also, is using computed columns slow vs storing the actual value?
(
dept_id INT,
build_id INT,
account_nbr COMPUTED BY (dept_id || '-' || build_id),
PRIMARY KEY(account_nbr)
);
It complains that I cannot use an computed column for the index. How would I fix this?
Also, is using computed columns slow vs storing the actual value?