Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
PUBLIC CLOUD
PRIVATE CLOUD
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Intelligence (Analytics)
Syntax question
bren1519
Hi,
A simple question for those more experienced than I! I am trying to add a computed column using a "like" expression and wildcards but I can't get the syntax right.
if ( row["Description"] like '%BlackBerry%')
{2}
else
{null}
Not sure what I'm doing wrong. Help would be appreciated!
thx Brenda
Find more posts tagged with
Comments
mwilliams
Hi Brenda,
If you're just trying to find the word BlackBerry in a field, you could just do something like the following as your expression for the computed column:
if (row["Description"].indexOf("BlackBerry") != -1){
2;
}
else{
null;
}
The would search the field Description for the substring "BlackBerry" no matter what was around it.
bren1519
That worked brilliantly! Thanks very much for the assistance.
Regards,
Brenda
mwilliams
Brenda,
Not a problem. Let us know whenever you have questions!