I'm trying to select a specific record in a table and I get the following error:
005 Bad size 47378 for column URL at offset 0x24 in recid0x13b4aof \boarddb\sites.tbl in the function fbuftofld
100 Error in data, file \boarddb\sites.tbl, offset 0x13B4A
I created a table called sites that has indexes on 3 fields. I try to do the following query which gives me the error mentioned earlier:
select * from sites where URL like '%anysite%'
I do have an index on the field URL. I tried dropping the indexes and running the query, but still get the error. Here are the results from texis -version:
Commercial Version 3.01.984682785 of Mar 15, 2001 (i686-intel-winnt)
I'll let kai followup on the info he asked for, but I'm sure you don't want
like '%anysite%'
It should be
like 'anysite'
or
matches '%anysite%'
or most likely
matches 'anysite%'
which can take advantage of a regular index.
like wants a metamorph index and % has an entirely different meaning for like than for matches. Please see the manual sections about each.
It's likely the table has been corrupted, especially if you get the error when searching with no indexes. Copy the table into a new one and then rename it back:
cd /your/database
tsql "create table newtable as select * from sites"
tsql "drop table sites"
mv newtable.tbl sites.tbl
addtable sites.tbl
tsql "drop table newtable"
This will copy as much readable data as possible from sites.
Are you running as the correct user?
What are the ownership and perms on the table vs. who you are running as?
What was your complete addtable command line?