Search using regular expressions, asterisks or attributes

This article describes how to search for records by key or value using regular expressions or KaDeck's asterisk search feature.

 

Search queries can be saved in views for later access. Learn more about views.

 

Introduction

KaDeck offers three possibilities to filter data records:

  • Attribute Filters: in the case of structured data (e.g. JSON or Avro), data records can be quickly filtered out on the basis of attributes. 
  • Quick Processor: if you need more complex filter logic, you should use the Quick Processor. With JavaScript, extremely complex business logic can be mapped quickly. Learn more.
  • Search and regular expressions: the most limited way to search for records. Use asterisks to search for strings in records or use regular expressions for specific patterns.

The search functionality can be useful when working with no structured data. When working with Avro or JSON or a custom codec, we recommend using the attribute filters, as they are more convenient to use. Take a look at our Quick Processor feature for more complex queries.

 

Attribute Filters

In the Data Browser, click on a record to open the Detail View. Click on an attribute in the "Key" or "Value" box where the JSON object is displayed, to open the Filter Bubble.

mceclip1.png

In the case of structured data (e.g. JSON or Avro), data records can be quickly filtered out using attributes. In this example, a filter is created that filters out data records with a Fahrenheit value of over 30.

 

Search and regular expressions

If you are looking for records that contain a specific string or pattern, you can use our simple text search (with an asterisk or regular expressions):

 

mceclip2.png

The search bar allows you to find records that contain a certain character string or pattern (regex).

Connect to a server and go to the Data Browser. Select a stream that contains the records you want to search and click on "Search" in the top main menu of the record list.

You will see two input fields in the main menu now: depending on where you want to look for your search string, use the key or the value field. You can also search for a term in key and value independently.

 

Regular expressions

To use regular expressions in the search input field, write "regex:" followed by your regular expression.

Note: you always need to match the whole string.

Example:
We are looking for a key that contains "needle". We enter the following in the key search field:

regex:.*needle.*

 

Asterisk search

If you are looking for values that contain, begin, or end with a specific string, we recommend using an asterisk search. An asterisk (*) is placed at the beginning, at the end, or on both sides of the term, depending on what you are looking for.

 

Example:
Searching for data that contains "needle":

*needle* 

Searching for data with suffix "needle":

*needle

Searching for data with prefix "needle":

needle*

 

Was this article helpful?
0 out of 1 found this helpful

Comments

0 comments

Please sign in to leave a comment.