
Contributor III
2020-10-26
08:27 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Not equal <> is not working at script level varaible
below expression is not working at script level.
LET vWeek_End_Not <> date(max(week_ending)-7,'DD/MM/YYYY')
658 Views
2 Replies


MVP
2020-10-26
09:34 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
What about you change things like this?
LET vWeek_End_Not = date(max(week_ending)-7,'DD/MM/YYYY');
Then you put it into a where clause, for instance:
Load
Your_Fields
From your_db where week_ending <> '$(vWeek_End_Not)';
Try this out and tell us what happened.
Regards
Thiago Justen Teixeira Gonçalves
Farol BI
WhatsApp: 24 98152-1675
Skype: justen.thiago
Farol BI
WhatsApp: 24 98152-1675
Skype: justen.thiago

MVP
2020-10-27
02:27 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi @Abhi999
LET vWeek_End_Not <> date(max(week_ending)-7,'DD/MM/YYYY')
Max function not work in "Let" statement.
You need to try like below
Load max(week_ending) as MaxWeek resident yoursourcetable;
Let vWeek_End_Not = Date(Peek('MaxWeek')-7,'DD/MM/YYYY');
Load
* from your_Sourcetable where week_ending <> '$(vWeek_End_Not)';
Hope it helps
Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.
Please close the thread by marking correct answer & give likes if you like the post.
629 Views
