2023-04-16 22:07:36 +02:00
|
|
|
Server Programming Interface (SPI)
|
2023-03-27 13:23:27 +02:00
|
|
|
|
|
|
|
|
2023-04-16 22:07:36 +02:00
|
|
|
Overview
|
|
|
|
========
|
2023-03-27 13:23:27 +02:00
|
|
|
|
2023-04-16 22:07:36 +02:00
|
|
|
This folder contains results from an experiment by Joseph Xu
|
|
|
|
to use the Postgres SPI. They are not currently used at all
|
|
|
|
by the GNU Taler exchange.
|
2023-03-27 13:23:27 +02:00
|
|
|
|
|
|
|
|
2023-04-16 22:07:36 +02:00
|
|
|
Dependencies
|
|
|
|
============
|
2023-03-27 13:23:27 +02:00
|
|
|
|
2023-04-16 22:07:36 +02:00
|
|
|
These are the direct dependencies for compiling the code:
|
2023-03-27 13:23:27 +02:00
|
|
|
|
2023-04-16 22:07:36 +02:00
|
|
|
# apt-get install libpq-dev postgresql-server-dev-13
|
|
|
|
# apt-get install libkrb5-dev
|
|
|
|
# apt-get install libssl-dev
|
2023-03-27 13:23:27 +02:00
|
|
|
|
|
|
|
|
2023-04-16 22:07:36 +02:00
|
|
|
Compilation
|
|
|
|
===========
|
2023-03-27 13:23:27 +02:00
|
|
|
|
2023-04-16 22:07:36 +02:00
|
|
|
$ make
|
2023-03-27 13:23:27 +02:00
|
|
|
|
2023-04-16 22:07:36 +02:00
|
|
|
Loading functions
|
|
|
|
=================
|
2023-03-27 13:23:27 +02:00
|
|
|
|
2023-04-16 22:07:36 +02:00
|
|
|
# make install
|
|
|
|
$ psql "$DB_NAME" < own_test.sql
|
2023-03-27 13:23:27 +02:00
|
|
|
|
|
|
|
|
2023-04-16 22:07:36 +02:00
|
|
|
Calling functions
|
|
|
|
==================
|
2023-03-27 13:23:27 +02:00
|
|
|
|
2023-04-16 22:07:36 +02:00
|
|
|
$ psql -c "SELECT $FUNCTION_NAME($ARGS);" "$DB_NAME"
|