回答編集履歴
4
追記
test
CHANGED
@@ -1,2 +1,5 @@
|
|
1
1
|
[dblink_exec](https://www.postgresql.jp/document/12/html/contrib-dblink-exec.html)では、接続先で、dblink_execを実行する側のテーブルの参照などは出来ません。
|
2
2
|
Bテーブルのトリガーで、`values select ~`ではなく、Bテーブルの値を読み取り、`values(0, 'a', '{"a0","b0","c0"}')`のような値を指定した文字列を組み立てる必要があります。
|
3
|
+
以下参考
|
4
|
+
[PostgreSQL トリガーで外部プログラムを実行する方法](https://www.ecomottblog.com/?p=2762)
|
5
|
+
|
3
推敲
test
CHANGED
@@ -1,4 +1,2 @@
|
|
1
|
-
[dblink_exec](https://www.postgresql.jp/document/12/html/contrib-dblink-exec.html)は接続先で実行する
|
1
|
+
[dblink_exec](https://www.postgresql.jp/document/12/html/contrib-dblink-exec.html)では、接続先で、dblink_execを実行する側のテーブルの参照などは出来ません。
|
2
|
-
|
3
|
-
接続先では、dblink_execを実行する側のテーブルの参照などは出来ません。
|
4
2
|
Bテーブルのトリガーで、`values select ~`ではなく、Bテーブルの値を読み取り、`values(0, 'a', '{"a0","b0","c0"}')`のような値を指定した文字列を組み立てる必要があります。
|
2
推敲
test
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
[dblink_exec](https://www.postgresql.jp/document/1
|
1
|
+
[dblink_exec](https://www.postgresql.jp/document/12/html/contrib-dblink-exec.html)は接続先で実行するコマンドを文字列で指定するものです。
|
2
2
|
|
3
3
|
接続先では、dblink_execを実行する側のテーブルの参照などは出来ません。
|
4
4
|
Bテーブルのトリガーで、`values select ~`ではなく、Bテーブルの値を読み取り、`values(0, 'a', '{"a0","b0","c0"}')`のような値を指定した文字列を組み立てる必要があります。
|
1
追記
test
CHANGED
@@ -1,4 +1,4 @@
|
|
1
1
|
[dblink_exec](https://www.postgresql.jp/document/15/html/contrib-dblink-exec.html)は接続先で実行するコマンドを文字列で指定するものです。
|
2
2
|
|
3
3
|
接続先では、dblink_execを実行する側のテーブルの参照などは出来ません。
|
4
|
-
`values select ~`ではなく、Bテーブルの値を読み取り、`values(0, 'a', '{"a0","b0","c0"}')`のような値を指定した文字列を組み立てる必要があります。
|
4
|
+
Bテーブルのトリガーで、`values select ~`ではなく、Bテーブルの値を読み取り、`values(0, 'a', '{"a0","b0","c0"}')`のような値を指定した文字列を組み立てる必要があります。
|