SQL Server & SQL Databases
A SELECT statement is a tag source, not an export job
Plenty of plant data never reaches a protocol endpoint. Setpoints, recipe numbers, lab results, shift targets and order quantities live in a MES, ERP or LIMS table and nowhere else. The ScadaHud SQL driver binds those columns straight to tags: you write a SELECT, and its results become live values that behave exactly like values read from a PLC.
What is SQL?
There is no "SQL protocol" in the fieldbus sense. What there is, in almost every plant, is a relational database holding the context the control network does not carry. ScadaHud connects to Microsoft SQL Server, PostgreSQL, MySQL / MariaDB and SQLite through their standard client libraries, runs a query you define on a polling interval, and maps the result onto tags. The driver is read-only by design: a tag bound to a SELECT has nowhere meaningful to write back to, so a write is rejected rather than guessed at.
What ScadaHud's driver supports
- Microsoft SQL Server, PostgreSQL, MySQL / MariaDB and SQLite
- Query groups: every tag sharing a query causes exactly one execution per poll, not one query per tag
- Column mode, a wide reading row where each tag takes its own column
- Row mode, a tall key/value table where each tag matches its own row on a key column
- Parameterized queries: @placeholders bind as real database parameters from constants or other tags’ live values, never string substitution
- Tags stay ordinary scalar tags, so historian, alarms, scaling and calculated tags all keep working
- Configurable polling, deadband, retry and reconnect
- Read-only by design: a write to a SQL-backed tag is refused, never turned into a guessed UPDATE
Common use cases
- Setpoints, recipes and shift targets held in a MES or ERP table
- Lab and quality results from a LIMS, trended and alarmed next to process values
- Production orders and batch numbers shown as context on mimics and dashboards
- Meter or billing readings another system has already collected into a database
- Bridging a legacy application that has a database but no protocol interface
Microsoft SQL Server, PostgreSQL, MySQL, MariaDB and SQLite. In practice: any MES, ERP, LIMS, historian or line-of-business application backed by one of these engines.
Book a live walkthrough.
Book a 30-minute live demo with one of our solution engineers. We will connect to a sample PLC and walk through tags, alarms, mimics, the digital twin, and historian queries.
