Replacing one column with another column if null [message #1844602] |
Fri, 17 September 2021 11:11  |
Eclipse User |
|
|
|
Hi,
I would really appreciate some advice with this
I have two columns which are giving results, one as email addresses and one as contact numbers = telephone, mobile, mobile2.
When the email result is null then the contact number contains a number.
These are separate communication methods from a table in sql.
What I would like to do is create a new computed column for both the email address and the telephone number, when emailaddress is null then replace with contactnumber = contact
I've looked at a few similar questions and found that entering the below script into the birt expression builder is accepted when you click validate, but it is not loading the report in the erp software I am using.
Is the expression itself correct?
if(row["destination"] == null){
row["contact"];
}
else if(row["contactnumber"] == null){
row["contact"];
}
else{
return true;
}
Kind regards,
Stuart
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.02886 seconds