Qlik Community

New to Qlik Sense

If you’re new to Qlik Sense, start with this Discussion Board and get up-to-speed quickly.

Announcements
QlikWorld 2022, LIVE in Denver CO., May 16-19, 2022. REGISTER NOW TO RECEIVE EARLY BIRD PRICING
cancel
Showing results for 
Search instead for 
Did you mean: 
PaoloGuerra
Creator
Creator

Excluding same values from column directly with code

Hi all,

I have this table and I need to automatically exclude some values ​​from the column Db_User_Name. And I would like to do it directly in the code. For example, I would like to exclude the two values: NT AUTHORITY\SYSTEM and DBSNMP.

Can you help me please?

 

exclude.jpg

 

 

Labels (1)
1 Solution

Accepted Solutions
Vegar
MVP
MVP

 Remove the first row.

Use only

If(match(Db_User_Name,'NT AUTHORITY\SYSTEM', 'DBSNMP')=0,
Db_User_Name,
Null()
)

Plees ekskuse my Swenglish and or Norweglish spelling misstakes

View solution in original post

8 Replies
walxiney_Planner

Hi

I think you can use the Drop Fields() take a look here... https://help.qlik.com/en-US/sense/June2018/Subsystems/Hub/Content/Scripting/ScriptRegularStatements/...
I don't sure but I think you can use "where" with drop fields, try it.

I hope this was help you.

PaoloGuerra
Creator
Creator
Author

Hi @walxiney_Planner 

thanks for the reply. Maybe I didn't write well. I would like to automatically filter some values ​​using the function.
I'm not sure if the drop command is the right one or am I wrong?

 

function.jpg

Vegar
MVP
MVP

Try this:
If(match(Db_User_Name,'NT AUTHORITY\SYSTEM', 'DBSNMP')=0,
Db_User_Name,
Null()
)
Plees ekskuse my Swenglish and or Norweglish spelling misstakes
PaoloGuerra
Creator
Creator
Author

garbage.jpg

Vegar
MVP
MVP

 Remove the first row.

Use only

If(match(Db_User_Name,'NT AUTHORITY\SYSTEM', 'DBSNMP')=0,
Db_User_Name,
Null()
)

Plees ekskuse my Swenglish and or Norweglish spelling misstakes

View solution in original post

walxiney_Planner

The response of Vegar is correct

Use just the

If(match(Db_User_Name,'NT AUTHORITY\SYSTEM', 'DBSNMP')=0,
Db_User_Name,
Null()
)

Don't need the first line  😊.

PaoloGuerra
Creator
Creator
Author

Thank you @Vegar ,  this is not the first time that you help me!!!

Vegar
MVP
MVP

Glad to be of help 💁
Plees ekskuse my Swenglish and or Norweglish spelling misstakes