Skip to content
DataMiner DoJo

More results...

Generic selectors
Exact matches only
Search in title
Search in content
Post Type Selectors
Search in posts
Search in pages
Search in posts
Search in pages
Log in
Menu
  • Updates & Insights
  • Questions
  • Learning
    • E-learning Courses
    • Empower Replay: Limited Edition
    • Tutorials
    • Open Classroom Training
    • Certification
      • DataMiner Fundamentals
      • DataMiner Configurator
      • DataMiner Automation
      • Scripts & Connectors Developer: HTTP Basics
      • Scripts & Connectors Developer: SNMP Basics
      • Visual Overview – Level 1
      • Verify a certificate
    • Video Library
    • Books We Like
    • >> Go to DataMiner Docs
  • Expert Center
    • Solutions & Use Cases
      • Solutions
      • Use Case Library
    • Markets & Industries
      • Media production
      • Government & defense
      • Content distribution
      • Service providers
      • Partners
      • OSS/BSS
    • Agile
      • Agile Webspace
      • Everything Agile
        • The Agile Manifesto
        • Best Practices
        • Retro Recipes
      • Methodologies
        • The Scrum Framework
        • Kanban
        • Extreme Programming
      • Roles
        • The Product Owner
        • The Agile Coach
        • The Quality & UX Coach (QX)
    • DataMiner DevOps Professional Program
      • About the DevOps Program
      • DataMiner DevOps Support
  • Downloads
  • More
    • DataMiner Releases & Updates
    • Feature Suggestions
    • Climb the leaderboard!
    • Swag Shop
    • Contact
    • Global Feedback Survey
  • PARTNERS
    • All Partners
    • Technology Partners
    • Strategic Partner Program
    • Deal Registration
  • >> Go to dataminer.services

Automation – filter on table – ColumnFilter OR

Solved1.02K views20th September 2023Automation
5
Leander Druwel [SLC] [DevOps Member]2.02K 18th September 2023 0 Comments

Hello,

I'm currently using the Skyline.DataMiner.Core.DataMinerSystem.Automation NuGet package to perform filtering on a table in an automation script. In my code, I've already set up a filter to retrieve rows with the value "4" in parameter 1003:

List<ColumnFilter> filter = new List<ColumnFilter>();
filter.Add(new ColumnFilter { Pid = 1003, Value = "4", ComparisonOperator = ComparisonOperator.Equal });
IEnumerable<object[]> filterTable = element.GetTable(1000).QueryData(filter);

Now, I'm looking to create a filter that retrieves rows with values "4" and "2" and apply it within the same query. Is there a way to indicate that multiple filters should be executed with an OR statement?

Thank you.

Marieke Goethals [SLC] [DevOps Catalyst] Selected answer as best 20th September 2023

1 Answer

  • Active
  • Voted
  • Newest
  • Oldest
3
Laurens Moutton [SLC] [DevOps Enabler]8.78K Posted 18th September 2023 1 Comment

Hi,

The ColumnFilter translates in the background to an SLNet filter, similar like is being used when executing a dynamic table query.

In that case, when there are multiple parameters included in the filter:
-When the parameter IDs are the same, then for these they are treated as logical OR (= select where pid X has value A OR pid X has value B)
-When the parameter IDs are different, then these are treated as logical AND (= select where pid X has value A AND pid Y has value B)

In the given example for pid 1003 to retrieve values "2" or "4", this becomes:

List<ColumnFilter> filter = new List<ColumnFilter>
{
new ColumnFilter { Pid = 1003, Value = "2", ComparisonOperator = ComparisonOperator.Equal },
new ColumnFilter { Pid = 1003, Value = "4", ComparisonOperator = ComparisonOperator.Equal },
};

IEnumerable<object[]> filterTable = element.GetTable(1000).QueryData(filter);

Regards,

Marieke Goethals [SLC] [DevOps Catalyst] Selected answer as best 20th September 2023
Leander Druwel [SLC] [DevOps Member] commented 19th September 2023

Alright, exactly what I was looking for. Thanks Laurens!

You are viewing 1 out of 1 answers, click here to view all answers.
Please login to be able to comment or post an answer.

My DevOps rank

DevOps Members get more insights on their profile page.

My user earnings

0 Dojo credits

Spend your credits in our swag shop.

0 Reputation points

Boost your reputation, climb the leaderboard.

Promo banner DataMiner DevOps Professiona Program
DataMiner Integration Studio (DIS)
Empower Katas
Privacy Policy • Terms & Conditions • Contact

© 2025 Skyline Communications. All rights reserved.

DOJO Q&A widget

Can't find what you need?

? Explore the Q&A DataMiner Docs

[ Placeholder content for popup link ] WordPress Download Manager - Best Download Management Plugin