[Gambas-user] Catch NULL character
Rodney Rundstrom
iecltd at ...2113...
Mon Apr 20 23:07:12 CEST 2009
Thanks for that I remember using isnull in visual basic and when =null
didn't work I checked isnull and found it worked.
Thanks again and sorry for any confusion
Rodney
-----Original Message-----
From: nando [mailto:nando_f at ...951...]
Sent: Monday, 20 April 2009 12:44 p.m.
To: mailing list for gambas users
Subject: Re: [Gambas-user] Catch NULL character
Actually, the NULL character is a true character.
Specifically, it is CHR$(0) <---zero.
It is an actual character in ASCII and other sets.
Alternatively, NULL is used in databases, Java, C, others
to describe certain situation.
Java: Null pointer is a pointer which has a value of zero and
therefore is an invalid reference and you'll get an exception.
C: Same thing, you'll get a seg fault or similar.
Databases: If the datatype is defined can be null, then the absence
of any value is NULL. It is completely possible to have a VARCHAR
and not allow null and have a string stored with CHAR(zero) in it.
It is a NULL character and not the NULL situation.
The lack of any string is a NULL situation and not a NULL character.
Usually, the absence of assigning a variable a value will result in
a NULL situation, not a NULL character.
Make sure you've got it correct or confusing results will follow.
-Fernando
---------- Original Message -----------
From: "Rodney Rundstrom" <iecltd at ...2113...>
To: "'mailing list for gambas users'" <gambas-user at lists.sourceforge.net>
Sent: Mon, 20 Apr 2009 10:56:29 +1200
Subject: Re: [Gambas-user] Catch NULL character
> As the NULL character is not a true character just a place holder you
should
> use ISNULL( )
>
> Ie if ISNULL(NULL) Then print "GOT it"
> Just change NULL for your variable
>
> Rodney Rundstrom
>
> -----Original Message-----
> From: CelticBhoy [mailto:weldon_gary at ...67...]
> Sent: Sunday, 29 March 2009 9:26 a.m.
> To: gambas-user at lists.sourceforge.net
> Subject: Re: [Gambas-user] Catch NULL character
>
> Thanx again for the help. I will have a look at your advice and try and
> implement it in my code. This is my first crack at programming since way
> back in the QuickBasic days, so I appreciate the help.
> --
> View this message in context:
> http://www.nabble.com/Catch-NULL-character-tp22751957p22760874.html
> Sent from the gambas-user mailing list archive at Nabble.com.
>
>
----------------------------------------------------------------------------
> --
> _______________________________________________
> Gambas-user mailing list
> Gambas-user at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/gambas-user
>
>
----------------------------------------------------------------------------
--
> Stay on top of everything new and different, both inside and
> around Java (TM) technology - register by April 22, and save
> $200 on the JavaOne (SM) conference, June 2-5, 2009, San Francisco.
> 300 plus technical and hands-on sessions. Register today.
> Use priority code J9JMT32. http://p.sf.net/sfu/p
> _______________________________________________
> Gambas-user mailing list
> Gambas-user at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/gambas-user
------- End of Original Message -------
----------------------------------------------------------------------------
--
Stay on top of everything new and different, both inside and
around Java (TM) technology - register by April 22, and save
$200 on the JavaOne (SM) conference, June 2-5, 2009, San Francisco.
300 plus technical and hands-on sessions. Register today.
Use priority code J9JMT32. http://p.sf.net/sfu/p
_______________________________________________
Gambas-user mailing list
Gambas-user at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user
More information about the User
mailing list