Strange error message
Posted in 2023
Topics: Data Types & Schema Design, Versions, Editions & End-of-Life
Greetings.
I'm running Version 14.10.FC9W1 on Linux.
I tried this for fun:
create table t1 (f1 char(100));
create index my_ix on t1 (f1[1,10]);26601: Cannot define a partial-column index on the non-character column, (f1).
$finderr 26601
-26601 Cannot define a partial-column index on the non-character column,
column-name.
You
can
specify a substring size in the CREATE INDEX statement
only
for
columns of character data types, such as
CHAR
, LVARCHAR, NCHAR, NVARCHAR,
or VARCHAR.
For the specified column, the index key must be the entire column value.
Remove the substring size value that follows the column name and rerun
the statement.
The error message implies that this should work.
Best regards,
-Snorri
------------------------------
Snorri Bergmann
------------------------------
Create an SPL that returns f1[1,10] and use that in the index definition
Thanks Paul. I know I can use a functional index but then sql-statements need to be modified accordingly :) Regards, -Snorri ------------------------------ Snorri Bergmann ------------------------------