Hi Hugo!

If i understood well, you need this (tested on Fb2.5.8):

select * from table where field = ascii_char(3) || ascii_char(1);

or

select * from table where ascii_val(substring(field from 1 for 1) = 3 and 
ascii_val(substring(field from 2 for 1) = 1;

András


From: firebird-support@yahoogroups.com 
[mailto:firebird-supp...@yahoogroups..com]
Sent: Friday, March 9, 2018 6:33 AM
To: firebird-support@yahoogroups.com
Subject: [firebird-support] ASCII values



Hello,

I have a column char(2) where two ASCII values stored. For example 00000011, 
00000001 are stored as (3,1).
When I do a select I dont get any result because the result is not 
alphanumeric. 3 is ETX and 1 is NUL.
I can get the values programmatically but I want to do bit comparison with sql 
query.
Anyone might know how?

Thx,
Hugo Larson





__________ Information from ESET Mail Security, version of virus signature 
database 17027 (20180309) __________

The message was checked by ESET Mail Security.
http://www.eset.com


[Non-text portions of this message have been removed]

Reply via email to