pljava
PL/Java procedural language
Overview
| Package | Version | Category | License | Language |
|---|---|---|---|---|
pljava | 1.6.10 | LANG | BSD-3-Clause | Java |
| ID | Extension | Bin | Lib | Load | Create | Trust | Reloc | Schema |
|---|---|---|---|---|---|---|---|---|
| 3090 | pljava | No | Yes | No | Yes | No | No | sqlj |
Version
| Type | Repo | Version | PG Ver | Package | Deps |
|---|---|---|---|---|---|
| EXT | PGDG | 1.6.10 | 1817161514 | pljava | - |
| RPM | PGDG | 1.6.10 | 1817161514 | pljava_$v | - |
| DEB | PGDG | 1.6.10 | 1817161514 | postgresql-$v-pljava | - |
Install
You can install pljava directly. First, make sure the PGDG repository is added and enabled:
Install the extension using pig or apt/yum/dnf:
Install
pig
dnf
apt
Create Extension:
Usage
pljava enables writing PostgreSQL functions, triggers, and types in Java using the standard JDBC API.
Deploy Java Code
Package your Java classes in a JAR file with an SQLJ deployment descriptor, then install it:
Create Functions
Write a Java class with static methods:
Declare the SQL function mapping:
Set-Returning Functions
Implement ResultSetProvider for set-returning functions:
Trigger Functions
Database Access via JDBC
JAR Management
Was this page helpful?
Thanks—your feedback helps us improve this page.
What got in the way? (optional)