hstore_plluau
Overview
| Package | Version | Category | License | Language |
|---|---|---|---|---|
pllua | 2.0.12 | LANG | MIT | C |
| ID | Extension | Bin | Lib | Load | Create | Trust | Reloc | Schema |
|---|---|---|---|---|---|---|---|---|
| 3020 | pllua | No | Yes | No | Yes | No | No | pg_catalog |
| 3021 | hstore_pllua | No | Yes | No | Yes | No | Yes | - |
| 3030 | plluau | No | Yes | No | Yes | No | No | pg_catalog |
| 3031 | hstore_plluau | No | Yes | No | Yes | No | Yes | pg_catalog |
| Related | hstore plluau hstore_plperl hstore_plperlu hstore_plpython3u plpgsql |
|---|
Version
| Type | Repo | Version | PG Ver | Package | Deps |
|---|---|---|---|---|---|
| EXT | MIXED | 2.0.12 | 1817161514 | pllua | hstore, plluau |
| RPM | PIGSTY | 2.0.12 | 1817161514 | pllua_$v | - |
| DEB | PGDG | 2.0.12 | 1817161514 | postgresql-$v-pllua | - |
| OS / PG | PG18 | PG17 | PG16 | PG15 | PG14 |
|---|---|---|---|---|---|
| el8.x86_64 | PIGSTY 2.0.12 | PIGSTY 2.0.12 | PIGSTY 2.0.12 | PIGSTY 2.0.12 | PIGSTY 2.0.12 |
| el8.aarch64 | PIGSTY 2.0.12 | PIGSTY 2.0.12 | PIGSTY 2.0.12 | PIGSTY 2.0.12 | PIGSTY 2.0.12 |
| el9.x86_64 | PIGSTY 2.0.12 | PIGSTY 2.0.12 | PIGSTY 2.0.12 | PIGSTY 2.0.12 | PIGSTY 2.0.12 |
| el9.aarch64 | PIGSTY 2.0.12 | PIGSTY 2.0.12 | PIGSTY 2.0.12 | PIGSTY 2.0.12 | PIGSTY 2.0.12 |
| el10.x86_64 | PIGSTY 2.0.12 | PIGSTY 2.0.12 | PIGSTY 2.0.12 | PIGSTY 2.0.12 | PIGSTY 2.0.12 |
| el10.aarch64 | PIGSTY 2.0.12 | PIGSTY 2.0.12 | PIGSTY 2.0.12 | PIGSTY 2.0.12 | PIGSTY 2.0.12 |
| d12.x86_64 | PGDG 2.0.12 | PGDG 2.0.12 | PGDG 2.0.12 | PGDG 2.0.12 | PGDG 2.0.12 |
| d12.aarch64 | PGDG 2.0.12 | PGDG 2.0.12 | PGDG 2.0.12 | PGDG 2.0.12 | PGDG 2.0.12 |
| d13.x86_64 | PGDG 2.0.12 | PGDG 2.0.12 | PGDG 2.0.12 | PGDG 2.0.12 | PGDG 2.0.12 |
| d13.aarch64 | PGDG 2.0.12 | PGDG 2.0.12 | PGDG 2.0.12 | PGDG 2.0.12 | PGDG 2.0.12 |
| u22.x86_64 | PGDG 2.0.12 | PGDG 2.0.12 | PGDG 2.0.12 | PGDG 2.0.12 | PGDG 2.0.12 |
| u22.aarch64 | PGDG 2.0.12 | PGDG 2.0.12 | PGDG 2.0.12 | PGDG 2.0.12 | PGDG 2.0.12 |
| u24.x86_64 | PGDG 2.0.12 | PGDG 2.0.12 | PGDG 2.0.12 | PGDG 2.0.12 | PGDG 2.0.12 |
| u24.aarch64 | PGDG 2.0.12 | PGDG 2.0.12 | PGDG 2.0.12 | PGDG 2.0.12 | PGDG 2.0.12 |
| u26.x86_64 | PGDG 2.0.12 | PGDG 2.0.12 | PGDG 2.0.12 | PGDG 2.0.12 | PGDG 2.0.12 |
| u26.aarch64 | PGDG 2.0.12 | PGDG 2.0.12 | PGDG 2.0.12 | PGDG 2.0.12 | PGDG 2.0.12 |
Install
You can install pllua directly. First, make sure the PGDG and PIGSTY repositories are added and enabled:
pig repo add pgsql -u # Add repo and update cache
Install the extension using pig or apt/yum/dnf:
pig install pllua; # Install for current active PG version
pig ext install -y pllua -v 18 # PG 18
pig ext install -y pllua -v 17 # PG 17
pig ext install -y pllua -v 16 # PG 16
pig ext install -y pllua -v 15 # PG 15
pig ext install -y pllua -v 14 # PG 14
dnf install -y pllua_18 # PG 18
dnf install -y pllua_17 # PG 17
dnf install -y pllua_16 # PG 16
dnf install -y pllua_15 # PG 15
dnf install -y pllua_14 # PG 14
apt install -y postgresql-18-pllua # PG 18
apt install -y postgresql-17-pllua # PG 17
apt install -y postgresql-16-pllua # PG 16
apt install -y postgresql-15-pllua # PG 15
apt install -y postgresql-14-pllua # PG 14
Create Extension:
CREATE EXTENSION hstore_plluau CASCADE; -- requires: hstore, plluau
Usage
The hstore_plluau extension provides a transform that allows hstore values to be passed directly to and from untrusted PL/Lua (plluau) functions as native Lua tables.
CREATE EXTENSION hstore;
CREATE EXTENSION plluau;
CREATE EXTENSION hstore_plluau;
Using hstore in plluau
With the transform installed, hstore arguments are automatically converted to Lua tables:
CREATE FUNCTION process_hstore(h hstore) RETURNS hstore LANGUAGE plluau AS $$
-- h is a Lua table with string keys and string values
h["processed"] = "true"
-- Can also do unrestricted operations (file I/O, etc.)
return h
$$;
SELECT process_hstore('key1 => "val1", key2 => "val2"'::hstore);
This is the untrusted counterpart to hstore_pllua. The behavior is identical – hstore values become Lua tables and vice versa – but functions run in the unrestricted plluau environment.
Feedback
Was this page helpful?
Thanks for the feedback! Please let us know how we can improve.
Sorry to hear that. Please let us know how we can improve.