Subject Re: [IBO] IndexFieldName with descending order
Author Jason Wharton
> With the old 4.8 IBO the indexfieldnames can set to
> MyTable.indexfieldname := 'MYFIELD desc'; and it worked fine for a
> descending order.
>
> But now with the 4.9 the Function IB_PARSE.ExtractFieldName was changed
> that the space out of a quoted text is now a indicator for a terminater.
>
> So - OK, I changed the IndexFieldname and quoted it into
> MyTable.indexfieldname := '"MYFIELD desc"';
>
> But the SQL the IBO-Parser send to the DB-Server leave the quotes, so the
> sql is
> select * from MyTable order by "MYFIELD desc"
>
> But such quoted orders are ignored by the SQL-Server. (as you can also
> quickly check wit a console like eg. ibexpert) - I suggest it do not
> interprete quoted stuff as fields or commands or smth else.
>
> ---------
> So simply Question: "From Version 4.9 How to set the IndexFieldNames
> Property of a TIBOTable to make a descending order ?"
> ---------

You can create a descending index if you don't already have one and then set
the IndexName to that index and it should work the way you want it to.

Let me know.

Jason Wharton