Subject Re: [firebird-support] unknown characters
Author Uwe Grauer
xuxu wrote:

> Help me!
> >firebird-support!
> >
> > There is some unknown charecters following the string-value in my
> table named xx.
> >
> >--MY
> TABLE--------------------------------------------------------------------------------
> > CREATE DOMAIN NUMBER_2 AS
> > VARCHAR(30) CHARACTER SET NONE
> > NOT NULL
> > COLLATE NONE
> >
> > create table xx(
> > DOMAINNO INTEGER NOT NULL,
> > ACCOUNTNO_DOMAIN NUMBER_2 NOT NULL,
> > USERTYPE CHAR(1) NOT NULL
> > ) ;
> >
> >--data----------------------------------------------------------------------------------------
>
> > Using 'select * from xx',I can get this :
> > DOMAINNO ACCOUNTNO_DOMAIN USERTYPE
> >============ ============================== ========
> > 17 826621 B
> > 17 911090
> > B
> >----------------------------------------------------------------------------------------------
>
> Using 'select len(accountno_domain) accountno_domain from xx ',I can
> get this :
> LEN ACCOUNTNO_DOMAIN
> =========== ================
> 6 826621
> 8 911090
> -----------------------------------------------------------------------------------------------
> Using 'select len(rtrim(acccounto_domain)) accounnto_domain from xx',I
> can get this:
> LEN ACCOUNTNO_DOMAIN
> =========== ================
> 6 826621
> 8 911090
> -----------------------------------------------------------------------------------------------
> What are the two characters following '911090' ? Help me!
>
> >
> >
> >
> >        xuxu
> >        xufh@...
> >          2004-11-30

Come on, you see that there are more characters than you expect.
These could be characters which get striped out by the output routines.
So, if you got wrong characters in your data, you want to fix your data.
Why not just update the Record with a valid value?
Or delete the Record and insert new values.

Uwe