Hi,
I'm using codebase to create table and index and i use VFP 9.0 to open the table and execute querys.
when i'm creating an index for one feild :
"CREATE INDEX ind ON person(age)"
every thing works fine and there the index is working well.
when i'm creating an index for two fields or more:
"CREATE INDEX ind ON person(age,name)"
VFP cant open the table.
what seems to be the problem
thanks ishay

using tow field index with codebase
Aaron Oneal
Would you try this (I don't use codebase to know if that'd work):
Create index ind On person(trans(age)+name)
John Papa
Your not getting any error from codebase doesn't mean it doesn't have any error. Behind the scenes what command(s) codebase is sending to VFP "Create index" isn't available in VFP (as it does in say MSSQL). AFAIK creating an index via OLEDB driver isn't even supported (and probably also not supported from ODBC driver) so it should be doing something else.
NoEgo
Create index ind On person(trans(age)+name) does not work, the problem isnt a syntax problem (I dont get any error code from code base when creating the index for two fields.
dczraptor
the first byte value is : 0x30
JustinA1
Can you tell the first byte value of table file Is 0x30
Beginning with vfp8 is something changed in table header(AutotIncrement) who can affect compability with codebase.
markovuksanovic
Philips-HCR
there is no problem with the table file ( I can open it and use it ) but only if I'm not using the .CDX file
so the problem is probably in the cdx file
K. Rose
I dont think code base is sending any thing to VFP i think they are creating table the are foxpro compitible.
when you say there is no way to create index using OLEDB you mean that there is no way to create index using OLEDB at all or just that the syntax is diffrent then MSSQL
and one last thing is it possible to create an index for two field in foxpro using VFP 9.0 or OLDDB or some other way
robhendershot
manick312938
What do you mean: "converted database in foxpro format" i'm using the "codebaseODBCStandfoxpro" driver to create the tables and indexs, so what kind of conversion did you make
AshMetry
Yes I think they're creating table and index lowlevel since it's easy to do so (and hopefully are aware of structure changes in VFP9).
I didn't say there is no way, I said it is not supported. Of course you can create an index for one field or multiple fields in foxpro. Syntax is different than that of MSSQL and you can use ExecScript() with VFPOLEDB provider. I would check created CDX using an hexeditor against a CDX structure. You should especially check bytes offset 512-1023 and 12-13. Compact index file structure along with other structures are full documented on MSDN help.
Will Merydith
Gunnar Adler