Query language

What is a query language?

The query language is comparable to a filter. More precisely, it is a database language that is used exclusively to search for data and is also used outside a Database can find use. In a query, you define which data you want to obtain from the entire available data stock (the database) - in mathematical terms, the subset of a total quantity is retrieved.

Popular areas of use are web applications, content management systems or application software; hardly any extensive software can do without the use of query languages. Depending on the system, they are beginner-friendly or require specialist knowledge. Often their complexity is also related to their cardinality, i.e. the question of the number of different subsets that can be formed by queries. Query languages can also be translated into each other, so queries can be created with an easy-to-understand syntax and translated into a "more powerful language" (with a higher cardinality) that is close to the machine.

Examples of popular query languages

  • For Graph databases has been particularly the Query language Cypher has prevailed. This is partly due to its easy-to-learn syntax, which allows complicated queries to be formulated despite its low threshold. Originally, Cypher was intended to be used exclusively for the graph database. Neo4j Thanks to a licensing change, the declarative language is now open source. Incidentally, queries to Neo4j databases respond with a result in the form of JSON - a popular format for the so-called response, as it is human-readable.
  • PromQL is also a query language designed for a special database; this is the database of the Monitoring software Prometheus. The software solution, initially written for Soundcloud - solutions available at the time did not meet the requirements - records and provides data over a period of time. A database query with PromQL provides a needs-based result that "fills with life" dashboards and alerts. Kibana is another analytics platform, comparable to Prometheus - but with the advantage of being able to integrate with the high-performance search engine Elasticsearch.
  • The Querying Languages JQL (Jira Query Language) and CQL (Confluence Query Language) get to know software developers who are involved in larger projects. Jira is a software tool that Web application for operational project management and for troubleshooting, and Confluence is a wiki software designed for documenting knowledge about the project being carried out - both solutions belong to the software-as-a-service provider Atlassian. When a team implements a project, it can use these languages to request data for an analytics dashboard, for example. Both languages are used in connection with advanced searches - i.e. searches that deliver very individual results thanks to extensive criteria.
  • Also the Kusto Query Language (KQL for short) should be understood in the context of the associated infrastructure. It is Part of the Microsoft Azure Data Explorer and is used exclusively for retrieving log data - the Azure Monitor Logs. Generally it resembles the well-known database language Structured Query Language (SQL for short). Databases are otherwise realised in the Azure infrastructure through SQL.

What distinguishes query languages from database languages?

Database languages can also query databases, but their functionality includes much more. They can manipulate (that is, add to, delete or replace) the databases' data, remove the entire database from memory or create a new database - including tables. A prominent example is the already mentioned Structured Query Language (SQL). The syntax (based on relational algebra) is relatively low-level and semantically based on human language. In various dialects, the language is used in numerous database systems. Moreover, database languages are only relevant in connection with databases. As a reminder, query languages can also be found in areas that are not directly related to a database.

Data Navigator Newsletter