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 gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Tables: left outer join: field with no content in formula

Status
Not open for further replies.

iemand

Programmer
Feb 17, 2003
7
NL
I joined two tables with a left outer join. In some cases this results in blank fields because records do not exist.
This is logical. BUT: I want to use a specific field that sometimes is blank in a formula like this: if the field has a content, take the value of the content otherwise take value 1.
This does not work. Some ideas?
 
Hi !

If you try and test for the blank first I think you will get it right.

if isNull({YourField}) then
'1'
else
{YourField}

/Goran
 
Just in case, add to that:

//If a number:
if isNull({YourField}) or {YourField} = 0 then
1
else
{YourField}

//If a string
if isNull({YourField}) or {YourField} = "" then
1
else
val({YourField})

-k kai@informeddatadecisions.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top