Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

What type of expression EMPTY() and ISBLANK() accepts?

Status
Not open for further replies.

IlyaRabyy

Programmer
Nov 9, 2010
571
US
Colleagues,
the subject says it!
issuing
Code:
loca for not isblank(loc_code)
results in the following error:

"Unallowed phrase/keyword in command: isblank(loc_code)"

issuing

Code:
loca for not empty(loc_code)

results in the similar error

"Unallowed phrase/keyword in command: empty(loc_code)"

Details:

Visual dBase ver. 5.7;

"loc_code" is the name of the field in a table currently openedin the currently selected work area.

What am I doing wrong?

TIA!

Regards,

Ilya
 
Ilya,

I don't recognise that error message. It doesn't look like a standard VFP error.

Oh, wait. Did you say "Visual dBase ver. 5.7"? You surely don't mean you're Visual dBase? If you are, why are you asking the question here?

Mike

__________________________________
Mike Lewis (Edinburgh, Scotland)

Visual FoxPro articles, tips, training, consultancy
 
Actually, I switched to the dBase forum here before posting... Apparently, it did not happen.
I shoulda paid more attentioon.
My apologies, Sir!

Regards,

Ilya
 
Probably something silly like dBase wanting an alias on that field name, or not having the right alias selected.

(dBase never was known for over-clear error messages. <g>)
 
I tried it with fully qualified field (i.e. EMPTY(ALIAS.FieldName)), even tried taking it in quotation marks (i.e. EMPTY("ALIAS.FieldName")) - same result: it erred.

I recall that, back in the days, FPD2, and even Clipper '87 worked much better (and were better documented) than dBase III...

Regards,

Ilya
 
By doing a Google search for dBase EMPTY() I came across:

On that link it says:
EMPTY()
This can be used on elements of an array to determine if they are really empty (undefined), or contain a value of false.


It would seem from that description that the EMPTY() function is related to use with Arrays 'elements' only - but I could be wrong.

Good Luck,
JRB-Bldr
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top