× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Maybe I'm missing something, but wouldn't you just do NAME <> '';

No space inside. Then won't it look to see if the value you are comparing
to is empty(all blanks)? That is how I do it in my sql statements....
then again, our text fields don't usually start with a blank so maybe I
have potential bugs all over the place.


Thanks
Bryce Martin
Programmer/Analyst I
570-546-4777



Alan Campin <alan0307d@xxxxxxxxx>
Sent by: midrange-l-bounces@xxxxxxxxxxxx
04/08/2010 07:38 PM
Please respond to
Midrange Systems Technical Discussion <midrange-l@xxxxxxxxxxxx>


To
Midrange Systems Technical Discussion <midrange-l@xxxxxxxxxxxx>
cc

Subject
Constraint comparing blanks.






When you are declare DDL for an SQL defined table we use a lot of stuff
like
this

NAME <> ' ';

I would have thought that this would expand to be compare say 10 char name
to 10 char blank but I saw today that is not true.

If you have the following in a field name the test will fail because it
only
looks at the first character.

<b>THOMAS<b><b><b> where <b> is a blank.

What is the correct way to declare this test? In RPG you have a *ALL' '
but
not in SQL.

You surely don't want to code

NAME <> ' '

I know there has to be a simple way to do it. Just can't think of it off
the
top of my head.

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.