|
5 | 5 | -- |
6 | 6 | ---- |
7 | 7 | DROP EXTENSION pgtt; |
8 | | -SHOW search_path ; |
9 | | - search_path |
10 | | ------------------------------- |
11 | | - "$user", public, pgtt_schema |
12 | | -(1 row) |
13 | 8 |
|
| 9 | +SHOW search_path ; |
14 | 10 | create schema first_schema; |
15 | 11 | create schema second_schema; |
16 | 12 | SET search_path TO "$user",public,pg_catalog,fisrt_schema,second_schema; |
17 | 13 | SHOW search_path ; |
18 | | - search_path |
19 | | ------------------------------------------------------------------------ |
20 | | - "$user", public, pg_catalog, fisrt_schema, second_schema, pgtt_schema |
21 | | -(1 row) |
22 | | - |
23 | 14 | CREATE EXTENSION pgtt; |
24 | 15 | SHOW search_path ; |
25 | | - search_path |
26 | | ------------------------------------------------------------------------ |
27 | | - "$user", public, pg_catalog, fisrt_schema, second_schema, pgtt_schema |
28 | | -(1 row) |
29 | | - |
30 | 16 | SET search_path TO pg_catalog; |
31 | 17 | SHOW search_path ; |
32 | | - search_path |
33 | | -------------------------- |
34 | | - pg_catalog, pgtt_schema |
35 | | -(1 row) |
36 | | - |
37 | 18 | SET search_path TO public; |
38 | 19 | SHOW search_path ; |
39 | | - search_path |
40 | | ---------------------- |
41 | | - public, pgtt_schema |
42 | | -(1 row) |
43 | 20 |
|
44 | 21 | -- Test only pg_catalog in search_path. |
45 | 22 | DROP EXTENSION pgtt; |
46 | 23 | \c - - |
47 | 24 | SHOW search_path; |
48 | | - search_path |
49 | | ------------------ |
50 | | - "$user", public |
51 | | -(1 row) |
52 | | - |
53 | 25 | SET search_path TO pg_catalog; |
54 | 26 | SHOW search_path; |
55 | | - search_path |
56 | | -------------- |
57 | | - pg_catalog |
58 | | -(1 row) |
59 | | - |
60 | 27 | CREATE EXTENSION pgtt; |
61 | 28 | SHOW search_path; |
62 | | - search_path |
63 | | --------------------------- |
64 | | - pgtt_schema, pg_catalog |
65 | | -(1 row) |
66 | 29 |
|
67 | 30 | -- Test the pg_catalog at end of search_path. |
68 | 31 | DROP EXTENSION pgtt; |
69 | 32 | \c - - |
70 | 33 | SET search_path TO "$user", public, pg_catalog; |
71 | 34 | SHOW search_path; |
72 | | - search_path |
73 | | ------------------------------ |
74 | | - "$user", public, pg_catalog |
75 | | -(1 row) |
76 | | - |
77 | 35 | CREATE EXTENSION pgtt; |
78 | 36 | SHOW search_path; |
79 | | - search_path |
80 | | ------------------------------------------- |
81 | | - "$user", public, pgtt_schema, pg_catalog |
82 | | -(1 row) |
83 | 37 |
|
| 38 | +-- Test empty search path like set by pg_dump |
| 39 | +SELECT pg_catalog.set_config('search_path', '', false); |
| 40 | +SHOW search_path; |
0 commit comments