File: localhost

package info (click to toggle)
postgresql-plproxy 2.10.0-8
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 652 kB
  • sloc: ansic: 3,458; sql: 1,112; lex: 340; yacc: 171; makefile: 97; sh: 17; awk: 14
file content (91 lines) | stat: -rw-r--r-- 3,639 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
Run tests via localhost so the unix socket location doesn't matter

--- a/test/expected/plproxy_test.out
+++ b/test/expected/plproxy_test.out
@@ -244,7 +244,7 @@ select * from test_types2('types', NULL,
 
 -- test CONNECT
 create function test_connect1() returns text
-as $$ connect 'dbname=test_part'; select current_database(); $$ language plproxy;
+as $$ connect 'dbname=test_part host=localhost'; select current_database(); $$ language plproxy;
 select * from test_connect1();
  test_connect1 
 ---------------
@@ -254,7 +254,7 @@ select * from test_connect1();
 -- test CONNECT $argument
 create function test_connect2(connstr text) returns text
 as $$ connect connstr; select current_database(); $$ language plproxy;
-select * from test_connect2('dbname=test_part');
+select * from test_connect2('dbname=test_part host=localhost');
  test_connect2 
 ---------------
  test_part
@@ -263,7 +263,7 @@ select * from test_connect2('dbname=test
 -- test CONNECT function($argument)
 create function test_connect3(connstr text) returns text
 as $$ connect text(connstr); select current_database(); $$ language plproxy;
-select * from test_connect3('dbname=test_part');
+select * from test_connect3('dbname=test_part host=localhost');
  test_connect3 
 ---------------
  test_part
@@ -409,7 +409,7 @@ NOTICE:  PL/Proxy: dropping stale conn
 ERROR:  public.test_error2(0): [test_part] REMOTE ERROR: column "err" does not exist at character 8
 create function test_error3() returns int4
 as $$
-    connect 'dbname=test_part';
+    connect 'dbname=test_part host=localhost';
 $$ language plproxy;
 select * from test_error3();
 ERROR:  public.test_error3(0): [test_part] REMOTE ERROR: function public.test_error3() does not exist at character 21
@@ -423,7 +423,7 @@ ERROR:  PL/Proxy function public.test_ba
 
 create function test_bad_db2() returns int4
 as $$
-    connect 'dbname=wrong_name_db';
+    connect 'dbname=wrong_name_db host=localhost';
 $$ language plproxy;
 select * from test_bad_db2();
 ERROR:  PL/Proxy function public.test_bad_db2(0): [wrong_name_db] PQconnectPoll: FATAL:  database "wrong_name_db" does not exist
--- a/test/sql/plproxy_test.sql
+++ b/test/sql/plproxy_test.sql
@@ -145,18 +145,18 @@ select * from test_types2('types', NULL,
 
 -- test CONNECT
 create function test_connect1() returns text
-as $$ connect 'dbname=test_part'; select current_database(); $$ language plproxy;
+as $$ connect 'dbname=test_part host=localhost'; select current_database(); $$ language plproxy;
 select * from test_connect1();
 
 -- test CONNECT $argument
 create function test_connect2(connstr text) returns text
 as $$ connect connstr; select current_database(); $$ language plproxy;
-select * from test_connect2('dbname=test_part');
+select * from test_connect2('dbname=test_part host=localhost');
 
 -- test CONNECT function($argument)
 create function test_connect3(connstr text) returns text
 as $$ connect text(connstr); select current_database(); $$ language plproxy;
-select * from test_connect3('dbname=test_part');
+select * from test_connect3('dbname=test_part host=localhost');
 
 -- test quoting function
 create type "RetWeird" as (
@@ -272,7 +272,7 @@ select * from test_error2();
 
 create function test_error3() returns int4
 as $$
-    connect 'dbname=test_part';
+    connect 'dbname=test_part host=localhost';
 $$ language plproxy;
 select * from test_error3();
 
@@ -285,7 +285,7 @@ select * from test_bad_db();
 
 create function test_bad_db2() returns int4
 as $$
-    connect 'dbname=wrong_name_db';
+    connect 'dbname=wrong_name_db host=localhost';
 $$ language plproxy;
 select * from test_bad_db2();