pyHQL brings the power of HQL (HighQSoft Query Language) to unlock your test data in Python. It provides a clean, Python-friendly way to query ASAM ODS data via the HQL Web Service, so you can focus on analysis instead of protocol details and low-level type handling.
pyHQL is designed for three audiences. Analysts and engineers use it for interactive exploration of test data in notebooks and short scripts. Developers use it to build reliable integrations and services on a consistent query layer. Data teams use it to feed Python workflows with results that fit analysis tasks—including time series, special types, and file-based artifacts.
pyHQL connects to an HQL Web Service endpoint and an ASAM ODS server using simple connection strings. The client supports clean session behavior (including disconnect/reconnect) and helps teams standardize one query layer across mixed landscapes—without re-implementing query plumbing in every script or service.
pyHQL makes it easy to explore ASAM ODS metadata and measured data in a way that aligns with how Python teams work. You can iterate quickly, inspect results as structured columns and values, and reuse the same query patterns across notebooks, CLI usage, and scripts. With SQL-like HQL syntax, queries remain readable and reviewable, allowing you to transition from data discovery to analysis without needing to build export tooling first.
Measured data often lives in large value matrices. With hqlvm queries, pyHQL retrieves mass data efficiently and keeps engineering context attached, including column metadata and units. That makes it easier to build robust calculations, plots, and reports without losing interpretation details.
pyHQL supports governed write workflows through explicit transactions, so inserts and updates follow the same rules as your system of record. It also supports downloading and uploading file content stored in ASAM ODS, helping teams keep reports and artifacts linked to the measurement context rather than scattered across local folders.
Install pyHQL as a supported HighQSoft Python package (for example, via pip from the provided distribution). Then connect with two strings: the HQL Web Service endpoint and the ASAM ODS connection URI. This approach works well for personal notebooks and shared team environments because the configuration remains small, explicit, and easy to replicate.
pyHQL preserves the richness of ASAM ODS data in Python-friendly forms. Access results by column name or index and work with values as native Python types. Where available, dates, complex-valued signals, external references, and physical units remain accessible through result objects—so downstream processing stays explicit and less error-prone.
Automation needs predictable behavior. pyHQL supports clean disconnect/reconnect patterns and handles open transactions safely when sessions end — uncommitted transactions are automatically rolled back on disconnect to avoid leftover locks. As part of the maintained HighQSoft HQL stack, pyHQL benefits from ongoing updates as standards and platforms evolve.
A typical workflow is to connect once, query metadata to identify measurements, then retrieve time series or value-matrix data for analysis. When needed, open a transaction to write results back or to manage file attachments in a controlled way.
from highqsoft.pyHQL.HQL import HQL
asam_ods_uri = "hql://user:password@ods_host:8788"
hql_service = "http://hql_service_host:9876"
hql = HQL(hql_service, asam_ods_uri)
# 1) Find data (metadata query)
res = hql.query("hql id, name, Created from aotest")
names = res.column("name").values()[0:5]
# 2) Retrieve mass data (time series / value matrix)
vm = hql.query("hqlvm * from aosubmatrix where id = 2")
signal = vm.column("SunnyMinutes").values()
unit = vm.column("SunnyMinutes").unit()
# 3) Write back results (transaction)
tid = hql.transaction()
hql.query(f"hqlinsert [TRANSACTION={tid}] values=(name='My Instance') into MyElement")
hql.transaction(commit=tid)
# 4) Download an attachment
hql.download("hql id, name from Attachment where id = 2", filename="report.bin")
# Clean shutdown (safe handling for open transactions)
hql.disconnect()
Run HQL as a centrally available REST endpoint so Python users can connect with pyHQL from their own environments. This is a strong fit for organizations that want shared access, consistent query behavior, and minimal client-side setup for many users.
Use pyHQL in notebooks for exploration, then promote the same code into scheduled scripts or pipeline steps. This creates a clean path from discovery to repeatable execution—especially when the same analysis must run consistently on new measurements.
Embed pyHQL in internal tools, scheduled jobs, and data services to standardize how Python accesses ASAM ODS through HQL. This keeps query logic consistent across teams and environments, and it ensures write operations and file handling stay governed through explicit transactions.
HighQSoft GmbH
Black-und-Decker-Straße 17b
D-65510 Idstein