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!

retreive one of two values

Status
Not open for further replies.

aalaa

Programmer
Apr 3, 2012
1
KW
hi,

i have 2 tables (table 1 ,table 2) all rows in table 1 are being displayed based on my query. but in table2 i have few records only. my problem is in case same records exist in both tables , i need to view records from table2 else records from table1. i wrote a formula for a field but what is showing is only records from table2
 
Try something like this:

If IsNull({table2.field}) then {table1.field} else {table2.field}

-Dell

A computer only does what you actually told it to do - not what you thought you told it to do.
 
Make sure you have joined your tables correctly as well.. Table1 one left outer join to Table2

_____________________________________
Crystal Reports XI Developer Version
Intersystems Cache 5.X ODBC connection

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top