Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
See why IDC MarketScape names Qlik a 2025 Leader! Read more
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Filter Conditin(and) in tMap help

Hello
Do you have some document regarding what kind of option we can use in the Filter Conditin(and) in tMap
exemple
I'm trying to filter data from table using this syntaxt
row2.projectID.equals(33) the projectID is a INT type
I have an error on my tMap "Orror on row2.projectID.equals(33) => Cannot invoke equals(int) on a primitive type int

And what is the correct syntaxt for not equals to 33 or to null?
THX
DN
Labels (2)
9 Replies
Anonymous
Not applicable
Author

Denis,
If your are in a JavaProject, the equal condition for a INTEGER is not the same that for a STRING.
Test in your case the following syntax : row2.projectID == 33
Regards.
Anonymous
Not applicable
Author

Thx Antoine
But how different working != or =! , <>,...
DN
Anonymous
Not applicable
Author

Antoine
and for null
how do you do?
row2.projectID == null doesn't work
Anonymous
Not applicable
Author

Denis,
An "Int" cannot be NULL but an "Integer" can be NULL.
Verify your Schema, and change with "Integer" (check Nullable -> true), and you can test your expression : row2.projectID == null
Regards
_AnonymousUser
Specialist III
Specialist III

Thak you cantoine
You helped me too.
Anonymous
Not applicable
Author

Hi all,
I am new to Talend. I am trying to figure out how to filter out an excel column based on the column name without writing java code. For example if I want to skip all the columns whose names start with 'derive_' can I do it with tMap or something else within Talend?
Thanks
Anonymous
Not applicable
Author

Maybe post this as a separate thread instead of hijacking this one. you'll get a better response.
My suggestion:
Add a tMap. On the right hand side add a field called "worksheet" with the following variable as the expression: (replace with the correct global name)
((String)globalMap.get("tFileInputExcel_1_CURRENT_SHEET"))
Then use tFilterRow to filter rows that include or exclude the worksheet names you want.
Let me know if this helps.
Anonymous
Not applicable
Author

My apologies for the intrusion. Could somebody be kind enough to show me how to post a new thread?
alevy
Specialist
Specialist

At the top of this topic, under the Announcement section, click the Usage, Operation link. On the new page at the right is a Post new topic link.