Subject Re: [IBO] Ordering in TIB_QUERY
Author L'Attila
I've found the next problem:

My IB_QUERY's SQL statement works from stored procedure's output
parameters, and if I change ordering (for searching) to a character-type
parameter (TTERMNEV CHAR(50)), it adds to my query: "ORDER BY TTERMNEV
ASC" and reorder.
But I need "ORDER BY TTERMNEV ASC COLLATE PXW_HUNDC" because of some
hungarian character (ÁÉÍÖ etc.).
Character set in database is OK (WIN1250). Database fields collating are
OK (PXW_HUNDC). Database connection (IBODATABASE) charset is OK (WIN1250).
It seems like SP's output parameters haven't got collate property.
How can I get the right order?

L'Attila wrote:

>Thanks, Jan!
>
>But... The character set is WIN1250 in database, collating PXW_HUNDC. And
>- It's good in IB_QUERY's select statement: "select name, code from
>table1 where..." adding orderingitem on field "name"
>- It's good in stored procedure (viewing in isql): "create procedure
>sp_any(i_one integer) returns(sp_name char(20), sp_code integer) begin
>for select name, code from table1 where... order by name into :sp_name,
>:sp_code; do suspend; end"
>- But it's not good if IB_QUERY's statement: "select sp_name, sp_code
>from sp_any(:i_any)" adding orderingitem on field "sp_name". If
>OrderingItemNo=0, then the order is good, but I can't search key by key.
>If OrderingItemNo=1, then I can search but the order is bad (...ZÖO"...).
>
>Jan Turner wrote:
>
>>You have to select the proper characterset in the collation property of the
>>database field on the server. Also your database connection needs a
>>character set that knows your special characters.
>>
>>hope this helps.
>>Turner
>>
>>"L'Attila" <ludati@...> schrieb im Newsbeitrag
>>news:3CF4EFFE.8000003@......
>>
>>>Hi All!
>>>
>>>In hungarian ABC there is some special character, for example the good
>>>order is: ...NOSVO"P...
>>>I've got an IB_QUERY. When I wrote a SELECT statement into IB_QUERY's
>>>SQL-property with OrderingItems , it orders fine (...NOSVO"P...).
>>>But I had to write this statement into stored procedure, and IB_QUERY's
>>>SQL only select from this procedure. It's faster, but when I add
>>>OrderingItem on a stringfield, it does not order well, it's doing:
>>>...NOP...ZVO"... Stored proc is good, it orders fine, but if I want to
>>>seek in a grid on this IB_QUERY, I have to define OrderingItem.
>>>
>>>Any idea?
>>>
>>>Thanks in advance:
>>>L'Attila
>>>
>>>
>>>
>>>
>>>
>>___________________________________________________________________________
>>
>>>IB Objects - direct, complete, custom connectivity to Firebird or
>>>
>>InterBase
>>
>>> without the need for BDE, ODBC or any other layer.
>>>
>>___________________________________________________________________________
>>
>>>http://www.ibobjects.com - your IBO community resource for Tech Info
>>>
>>papers,
>>
>>>keyword-searchable FAQ, community code contributions and more !
>>>
>>>Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
>>>
>>>
>>>
>>
>>
>>
>>___________________________________________________________________________
>>IB Objects - direct, complete, custom connectivity to Firebird or InterBase
>> without the need for BDE, ODBC or any other layer.
>>___________________________________________________________________________
>>http://www.ibobjects.com - your IBO community resource for Tech Info papers,
>>keyword-searchable FAQ, community code contributions and more !
>>
>>Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
>>
>>
>>
>>
>>
>
>
>
>
>
>___________________________________________________________________________
>IB Objects - direct, complete, custom connectivity to Firebird or InterBase
> without the need for BDE, ODBC or any other layer.
>___________________________________________________________________________
>http://www.ibobjects.com - your IBO community resource for Tech Info papers,
>keyword-searchable FAQ, community code contributions and more !
>
>Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
>
>
>
>
>