Hex Artifact Content
Not logged in

Artifact a58449a6571c1b1a6a16e2c4c47ef59275559cdc:

Wiki page [PostgreSQL] by sandro 2018-08-03 16:12:08.
0000: 44 20 32 30 31 38 2d 30 38 2d 30 33 54 31 36 3a  D 2018-08-03T16:
0010: 31 32 3a 30 38 2e 35 38 38 0a 4c 20 50 6f 73 74  12:08.588.L Post
0020: 67 72 65 53 51 4c 0a 50 20 37 37 61 61 61 65 30  greSQL.P 77aaae0
0030: 66 65 38 32 31 61 66 66 32 32 62 30 63 39 39 63  fe821aff22b0c99c
0040: 30 36 62 30 38 64 31 30 61 63 30 36 65 37 61 64  06b08d10ac06e7ad
0050: 34 0a 55 20 73 61 6e 64 72 6f 0a 57 20 37 36 37  4.U sandro.W 767
0060: 32 0a 42 61 63 6b 20 74 6f 20 3c 61 20 68 72 65  2.Back to <a hre
0070: 66 3d 22 68 74 74 70 73 3a 2f 2f 77 77 77 2e 67  f="https://www.g
0080: 61 69 61 2d 67 69 73 2e 69 74 2f 66 6f 73 73 69  aia-gis.it/fossi
0090: 6c 2f 73 70 61 74 69 61 6c 69 74 65 5f 67 75 69  l/spatialite_gui
00a0: 2f 77 69 6b 69 3f 6e 61 6d 65 3d 73 70 61 74 69  /wiki?name=spati
00b0: 61 6c 69 74 65 2d 67 75 69 22 3e 6d 61 69 6e 20  alite-gui">main 
00c0: 57 69 6b 69 20 70 61 67 65 3c 2f 61 3e 3c 68 72  Wiki page</a><hr
00d0: 3e 3c 62 72 3e 0d 0a 3c 68 31 3e 54 68 65 20 47  ><br>..<h1>The G
00e0: 55 49 20 61 73 20 61 20 50 6f 73 74 67 72 65 53  UI as a PostgreS
00f0: 51 4c 20 63 6c 69 65 6e 74 3c 2f 68 31 3e 0d 0a  QL client</h1>..
0100: 53 74 61 72 74 69 6e 67 20 66 72 6f 6d 20 76 65  Starting from ve
0110: 72 73 69 6f 6e 20 3c 62 3e 32 2e 31 2e 30 3c 2f  rsion <b>2.1.0</
0120: 62 3e 20 74 68 65 20 47 55 49 20 68 61 73 20 74  b> the GUI has t
0130: 68 65 20 63 61 70 61 62 69 6c 69 74 79 20 74 6f  he capability to
0140: 20 73 75 70 70 6f 72 74 20 63 6f 6e 6e 65 63 74   support connect
0150: 69 6f 6e 73 20 74 6f 20 65 78 74 65 72 6e 61 6c  ions to external
0160: 20 3c 62 3e 50 6f 73 74 67 72 65 53 51 4c 20 2f   <b>PostgreSQL /
0170: 20 50 6f 73 74 47 49 53 3c 2f 62 3e 20 64 61 74   PostGIS</b> dat
0180: 61 62 61 73 65 73 2e 3c 62 72 3e 0d 0a 54 68 69  abases.<br>..Thi
0190: 73 20 66 75 6e 63 74 69 6f 6e 61 6c 69 74 79 20  s functionality 
01a0: 69 73 20 6d 61 69 6e 6c 79 20 62 61 73 65 64 20  is mainly based 
01b0: 6f 6e 20 3c 61 20 68 72 65 66 3d 22 68 74 74 70  on <a href="http
01c0: 73 3a 2f 2f 77 77 77 2e 67 61 69 61 2d 67 69 73  s://www.gaia-gis
01d0: 2e 69 74 2f 66 6f 73 73 69 6c 2f 76 69 72 74 75  .it/fossil/virtu
01e0: 61 6c 70 67 2f 77 69 6b 69 3f 6e 61 6d 65 3d 74  alpg/wiki?name=t
01f0: 75 74 6f 72 69 61 6c 22 3e 6c 69 62 76 69 72 74  utorial">libvirt
0200: 75 61 6c 70 67 3c 2f 61 3e 2c 20 74 68 61 74 20  ualpg</a>, that 
0210: 69 73 20 6e 6f 77 20 61 20 72 65 71 75 69 72 65  is now a require
0220: 64 20 64 65 70 65 6e 64 65 6e 63 79 20 66 6f 72  d dependency for
0230: 20 74 68 65 20 47 55 49 20 74 6f 6f 6c 2e 0d 0a   the GUI tool...
0240: 54 68 65 20 70 72 65 73 65 6e 74 20 74 75 74 6f  The present tuto
0250: 72 69 61 6c 20 69 73 20 69 6e 74 65 6e 64 65 64  rial is intended
0260: 20 74 6f 20 71 75 69 63 6b 6c 79 20 65 78 70 6c   to quickly expl
0270: 61 69 6e 20 68 6f 77 20 74 68 65 20 50 6f 73 74  ain how the Post
0280: 67 72 65 53 51 4c 20 73 75 70 70 6f 72 74 20 69  greSQL support i
0290: 73 20 69 6d 70 6c 65 6d 65 6e 74 65 64 20 62 79  s implemented by
02a0: 20 3c 62 3e 73 70 61 74 69 61 6c 69 74 65 5f 67   <b>spatialite_g
02b0: 75 69 3c 2f 62 3e 2e 3c 62 72 3e 3c 62 72 3e 0d  ui</b>.<br><br>.
02c0: 0a 3c 74 61 62 6c 65 20 63 65 6c 6c 73 70 61 63  .<table cellspac
02d0: 69 6e 67 3d 22 36 22 20 63 65 6c 6c 70 61 64 64  ing="6" cellpadd
02e0: 69 6e 67 3d 22 36 22 20 62 67 63 6f 6c 6f 72 3d  ing="6" bgcolor=
02f0: 22 66 30 66 66 65 30 22 20 77 69 64 74 68 3d 22  "f0ffe0" width="
0300: 31 30 30 25 22 20 62 6f 72 64 65 72 3d 22 31 22  100%" border="1"
0310: 3e 0d 0a 3c 74 72 3e 3c 74 64 20 63 6f 6c 73 70  >..<tr><td colsp
0320: 61 6e 3d 22 32 22 20 61 6c 69 67 6e 3d 22 63 65  an="2" align="ce
0330: 6e 74 65 72 22 3e 3c 68 33 3e 31 20 2d 20 45 73  nter"><h3>1 - Es
0340: 74 61 62 6c 69 73 68 69 6e 67 20 61 20 43 6f 6e  tablishing a Con
0350: 6e 65 63 74 69 6e 67 20 74 6f 20 61 20 50 6f 73  necting to a Pos
0360: 74 67 72 65 53 51 4c 20 44 42 4d 53 3c 2f 68 33  tgreSQL DBMS</h3
0370: 3e 3c 68 72 3e 3c 2f 74 64 3e 3c 2f 74 72 3e 0d  ><hr></td></tr>.
0380: 0a 3c 74 72 3e 0d 0a 3c 74 64 3e 3c 62 3e 31 2e  .<tr>..<td><b>1.
0390: 61 3c 2f 62 3e 20 79 6f 75 20 63 61 6e 20 70 72  a</b> you can pr
03a0: 65 73 73 20 74 68 65 20 61 70 70 72 6f 70 72 69  ess the appropri
03b0: 61 74 65 20 62 75 74 74 6f 6e 20 66 72 6f 6d 20  ate button from 
03c0: 74 68 65 20 54 6f 6f 6c 62 61 72 3c 2f 74 64 3e  the Toolbar</td>
03d0: 0d 0a 3c 74 64 3e 3c 69 6d 67 20 73 72 63 3d 22  ..<td><img src="
03e0: 68 74 74 70 73 3a 2f 2f 77 77 77 2e 67 61 69 61  https://www.gaia
03f0: 2d 67 69 73 2e 69 74 2f 67 61 69 61 2d 73 69 6e  -gis.it/gaia-sin
0400: 73 2f 67 75 69 2d 70 6f 73 74 67 72 65 73 2f 67  s/gui-postgres/g
0410: 75 69 31 2e 70 6e 67 22 20 61 6c 74 3d 22 63 6f  ui1.png" alt="co
0420: 6e 6e 65 63 74 69 6f 6e 20 31 22 3e 3c 2f 74 64  nnection 1"></td
0430: 3e 0d 0a 3c 2f 74 72 3e 0d 0a 3c 74 72 3e 0d 0a  >..</tr>..<tr>..
0440: 3c 74 64 3e 3c 62 3e 31 2e 62 3c 2f 62 3e 20 79  <td><b>1.b</b> y
0450: 6f 75 20 63 61 6e 20 73 65 6c 65 63 74 20 74 68  ou can select th
0460: 65 20 61 70 70 72 6f 70 72 69 61 74 65 20 69 74  e appropriate it
0470: 65 6d 20 66 72 6f 6d 20 74 68 65 20 6d 61 69 6e  em from the main
0480: 20 4d 65 6e 75 3c 2f 74 64 3e 0d 0a 3c 74 64 3e   Menu</td>..<td>
0490: 3c 69 6d 67 20 73 72 63 3d 22 68 74 74 70 73 3a  <img src="https:
04a0: 2f 2f 77 77 77 2e 67 61 69 61 2d 67 69 73 2e 69  //www.gaia-gis.i
04b0: 74 2f 67 61 69 61 2d 73 69 6e 73 2f 67 75 69 2d  t/gaia-sins/gui-
04c0: 70 6f 73 74 67 72 65 73 2f 67 75 69 32 2e 70 6e  postgres/gui2.pn
04d0: 67 22 20 61 6c 74 3d 22 63 6f 6e 6e 65 63 74 69  g" alt="connecti
04e0: 6f 6e 20 32 22 3e 3c 2f 74 64 3e 0d 0a 3c 2f 74  on 2"></td>..</t
04f0: 72 3e 0d 0a 3c 2f 74 72 3e 0d 0a 3c 74 72 3e 0d  r>..</tr>..<tr>.
0500: 0a 3c 74 64 3e 3c 62 3e 31 2e 63 3c 2f 62 3e 20  .<td><b>1.c</b> 
0510: 61 6e 64 20 66 69 6e 61 6c 6c 79 20 79 6f 75 20  and finally you 
0520: 63 61 6e 20 73 65 6c 65 63 74 20 74 68 65 20 61  can select the a
0530: 70 70 72 6f 70 72 69 61 74 65 20 69 74 65 6d 20  ppropriate item 
0540: 66 72 6f 6d 20 74 68 65 20 63 6f 6e 74 65 78 74  from the context
0550: 20 4d 65 6e 75 20 74 68 61 74 20 77 69 6c 6c 20   Menu that will 
0560: 61 70 70 65 61 72 20 62 79 20 63 6c 69 63 6b 69  appear by clicki
0570: 6e 67 20 74 68 65 20 3c 62 3e 6c 65 66 74 3c 2f  ng the <b>left</
0580: 62 3e 20 62 75 74 74 6f 6e 20 6f 66 20 74 68 65  b> button of the
0590: 20 6d 6f 75 73 65 20 6f 76 65 72 20 74 68 65 20   mouse over the 
05a0: 3c 62 3e 50 6f 73 74 72 65 53 51 4c 3c 2f 62 3e  <b>PostreSQL</b>
05b0: 20 6d 61 69 6e 20 6e 6f 64 65 20 66 72 6f 6d 20   main node from 
05c0: 74 68 65 20 54 61 62 6c 65 20 54 72 65 65 2e 3c  the Table Tree.<
05d0: 2f 74 64 3e 0d 0a 3c 74 64 3e 3c 69 6d 67 20 73  /td>..<td><img s
05e0: 72 63 3d 22 68 74 74 70 73 3a 2f 2f 77 77 77 2e  rc="https://www.
05f0: 67 61 69 61 2d 67 69 73 2e 69 74 2f 67 61 69 61  gaia-gis.it/gaia
0600: 2d 73 69 6e 73 2f 67 75 69 2d 70 6f 73 74 67 72  -sins/gui-postgr
0610: 65 73 2f 67 75 69 33 2e 70 6e 67 22 20 61 6c 74  es/gui3.png" alt
0620: 3d 22 63 6f 6e 6e 65 63 74 69 6f 6e 20 33 22 3e  ="connection 3">
0630: 3c 2f 74 64 3e 0d 0a 3c 2f 74 72 3e 3c 74 72 3e  </td>..</tr><tr>
0640: 0d 0a 3c 74 64 3e 3c 62 3e 31 2e 64 3c 2f 62 3e  ..<td><b>1.d</b>
0650: 20 69 6e 20 61 6c 6c 20 74 68 72 65 65 20 63 61   in all three ca
0660: 73 65 73 20 74 68 65 20 50 6f 73 74 67 72 65 53  ses the PostgreS
0670: 51 4c 20 63 6f 6e 6e 65 63 74 69 6f 6e 20 64 69  QL connection di
0680: 61 6c 6f 67 20 77 69 6c 6c 20 61 70 70 65 61 72  alog will appear
0690: 2e 3c 62 72 3e 0d 0a 4a 75 73 74 20 69 6e 73 65  .<br>..Just inse
06a0: 72 74 20 74 68 65 20 72 65 71 75 69 72 65 64 20  rt the required 
06b0: 63 6f 6e 6e 65 63 74 69 6f 6e 20 61 72 67 75 6d  connection argum
06c0: 65 6e 74 73 20 61 6e 64 20 63 6f 6e 66 69 72 6d  ents and confirm
06d0: 2e 3c 62 72 3e 3c 62 72 3e 0d 0a 49 66 20 74 68  .<br><br>..If th
06e0: 65 20 67 69 76 65 6e 20 61 72 67 75 6d 65 6e 74  e given argument
06f0: 73 20 61 72 65 20 69 6e 76 61 6c 69 64 20 61 6e  s are invalid an
0700: 20 65 72 72 6f 72 20 6d 65 73 73 61 67 65 20 77   error message w
0710: 69 6c 6c 20 62 65 20 74 68 65 6e 20 64 69 73 70  ill be then disp
0720: 6c 61 79 65 64 2c 20 6f 74 68 72 77 69 73 65 20  layed, othrwise 
0730: 74 68 65 20 63 6f 6e 6e 65 63 74 69 6f 6e 20 77  the connection w
0740: 69 6c 6c 20 62 65 20 69 6d 6d 65 64 69 61 74 65  ill be immediate
0750: 6c 79 20 65 73 74 61 62 6c 69 73 68 65 64 2e 3c  ly established.<
0760: 62 72 3e 3c 62 72 3e 3c 62 72 3e 3c 68 72 3e 3c  br><br><br><hr><
0770: 62 72 3e 3c 62 72 3e 3c 62 72 3e 0d 0a 49 66 20  br><br><br>..If 
0780: 79 6f 75 20 61 72 65 20 61 74 74 65 6d 70 74 69  you are attempti
0790: 6e 67 20 74 6f 20 63 6f 6e 6e 65 63 74 20 61 20  ng to connect a 
07a0: 72 65 6d 6f 74 65 20 73 65 72 76 65 72 2c 20 79  remote server, y
07b0: 6f 75 20 63 6f 75 6c 64 20 70 72 6f 62 61 62 6c  ou could probabl
07c0: 79 20 66 69 6e 64 20 75 73 65 66 75 6c 20 72 65  y find useful re
07d0: 61 64 69 6e 67 20 66 69 72 73 74 20 74 68 65 20  ading first the 
07e0: 74 75 74 6f 72 69 61 6c 20 61 62 6f 75 74 20 3c  tutorial about <
07f0: 61 20 68 72 65 66 3d 22 68 74 74 70 73 3a 2f 2f  a href="https://
0800: 77 77 77 2e 67 61 69 61 2d 67 69 73 2e 69 74 2f  www.gaia-gis.it/
0810: 66 6f 73 73 69 6c 2f 76 69 72 74 75 61 6c 70 67  fossil/virtualpg
0820: 2f 77 69 6b 69 3f 6e 61 6d 65 3d 70 6f 72 74 2d  /wiki?name=port-
0830: 66 6f 72 77 61 72 64 69 6e 67 22 3e 53 53 48 20  forwarding">SSH 
0840: 74 75 6e 6e 65 6c 69 6e 67 20 61 6e 64 20 50 6f  tunneling and Po
0850: 72 74 20 46 6f 72 77 61 72 64 69 6e 67 3c 2f 61  rt Forwarding</a
0860: 3e 3c 2f 74 64 3e 0d 0a 3c 74 64 3e 3c 69 6d 67  ></td>..<td><img
0870: 20 73 72 63 3d 22 68 74 74 70 73 3a 2f 2f 77 77   src="https://ww
0880: 77 2e 67 61 69 61 2d 67 69 73 2e 69 74 2f 67 61  w.gaia-gis.it/ga
0890: 69 61 2d 73 69 6e 73 2f 67 75 69 2d 70 6f 73 74  ia-sins/gui-post
08a0: 67 72 65 73 2f 67 75 69 34 2e 70 6e 67 22 20 61  gres/gui4.png" a
08b0: 6c 74 3d 22 63 6f 6e 6e 65 63 74 69 6f 6e 20 34  lt="connection 4
08c0: 22 3e 3c 2f 74 64 3e 0d 0a 3c 2f 74 72 3e 0d 0a  "></td>..</tr>..
08d0: 3c 74 72 3e 3c 74 64 20 63 6f 6c 73 70 61 6e 3d  <tr><td colspan=
08e0: 22 32 22 20 61 6c 69 67 6e 3d 22 63 65 6e 74 65  "2" align="cente
08f0: 72 22 3e 3c 68 33 3e 32 20 2d 20 45 78 70 61 6e  r"><h3>2 - Expan
0900: 64 69 6e 67 20 74 68 65 20 50 6f 73 74 67 72 65  ding the Postgre
0910: 53 51 4c 20 74 72 65 65 3c 2f 68 33 3e 3c 68 72  SQL tree</h3><hr
0920: 3e 3c 2f 74 64 3e 3c 2f 74 72 3e 0d 0a 3c 74 72  ></td></tr>..<tr
0930: 3e 0d 0a 3c 74 64 3e 3c 62 3e 32 2e 61 3c 2f 62  >..<td><b>2.a</b
0940: 3e 20 6f 6e 63 65 20 74 68 61 74 20 61 20 6e 65  > once that a ne
0950: 77 20 50 6f 73 74 67 72 65 73 20 63 6f 6e 6e 65  w Postgres conne
0960: 63 74 69 6f 6e 20 68 61 73 20 62 65 65 6e 20 73  ction has been s
0970: 75 63 63 65 73 66 75 6c 6c 79 20 65 73 74 61 62  uccesfully estab
0980: 6c 69 73 68 65 64 20 74 68 65 20 50 6f 73 74 67  lished the Postg
0990: 72 65 73 20 6e 6f 64 65 20 6f 6e 20 74 68 65 20  res node on the 
09a0: 6d 61 69 6e 20 54 61 62 6c 65 20 54 72 65 65 20  main Table Tree 
09b0: 77 69 6c 6c 20 63 6f 6e 74 61 69 6e 20 61 6c 6c  will contain all
09c0: 20 54 61 62 6c 65 73 20 61 6e 64 20 56 69 65 77   Tables and View
09d0: 73 20 64 65 66 69 6e 65 64 20 6f 6e 20 74 68 65  s defined on the
09e0: 20 50 6f 73 74 67 72 65 73 20 44 61 74 61 62 61   Postgres Databa
09f0: 73 65 2c 20 61 63 63 6f 72 64 69 6e 67 6c 79 20  se, accordingly 
0a00: 74 6f 20 74 68 65 20 75 73 75 61 6c 20 61 72 72  to the usual arr
0a10: 61 6e 67 65 6d 65 6e 74 20 61 64 6f 70 74 65 64  angement adopted
0a20: 20 62 79 20 50 6f 73 74 67 72 65 73 3a 0d 0a 3c   by Postgres:..<
0a30: 75 6c 3e 0d 0a 3c 6c 69 3e 43 6f 6e 6e 65 63 74  ul>..<li>Connect
0a40: 69 6f 6e 20 3c 69 3e 61 6b 61 3c 2f 69 3e 20 3c  ion <i>aka</i> <
0a50: 62 3e 44 61 74 61 62 61 73 65 3c 2f 62 3e 0d 0a  b>Database</b>..
0a60: 3c 75 6c 3e 0d 0a 3c 6c 69 3e 3c 62 3e 53 63 68  <ul>..<li><b>Sch
0a70: 65 6d 61 3c 2f 62 3e 0d 0a 3c 75 6c 3e 0d 0a 3c  ema</b>..<ul>..<
0a80: 6c 69 3e 3c 62 3e 54 61 62 6c 65 3c 2f 62 3e 20  li><b>Table</b> 
0a90: 6f 72 20 3c 62 3e 56 69 65 77 3c 2f 62 3e 3c 2f  or <b>View</b></
0aa0: 6c 69 3e 0d 0a 3c 2f 75 6c 3e 3c 2f 6c 69 3e 0d  li>..</ul></li>.
0ab0: 0a 3c 2f 75 6c 3e 3c 2f 6c 69 3e 0d 0a 3c 2f 75  .</ul></li>..</u
0ac0: 6c 3e 3c 62 72 3e 3c 62 72 3e 0d 0a 45 61 63 68  l><br><br>..Each
0ad0: 20 6b 69 6e 64 20 6f 66 20 64 61 74 61 62 61 73   kind of databas
0ae0: 65 20 6f 62 6a 65 63 74 20 77 69 6c 6c 20 62 65  e object will be
0af0: 20 63 6c 65 61 72 6c 79 20 69 64 65 6e 74 69 66   clearly identif
0b00: 69 65 64 20 62 79 20 61 6e 20 61 70 70 72 6f 70  ied by an approp
0b10: 72 69 61 74 65 20 69 63 6f 6e 3b 20 56 69 65 77  riate icon; View
0b20: 73 20 77 69 6c 6c 20 62 65 20 64 69 73 74 69 6e  s will be distin
0b30: 67 75 69 73 68 65 64 20 66 72 6f 6d 20 54 61 62  guished from Tab
0b40: 6c 65 73 2c 20 61 6e 64 20 3c 62 3e 50 6f 73 74  les, and <b>Post
0b50: 47 49 53 3c 2f 62 3e 20 54 61 62 6c 65 73 20 28  GIS</b> Tables (
0b60: 63 6f 6e 74 61 69 6e 69 6e 67 20 3c 62 3e 47 65  containing <b>Ge
0b70: 6f 6d 65 74 72 79 3c 2f 62 3e 20 63 6f 6c 75 6d  ometry</b> colum
0b80: 6e 73 29 20 77 69 6c 6c 20 62 65 20 63 6c 65 61  ns) will be clea
0b90: 72 6c 79 20 64 69 73 74 69 6e 67 75 69 73 68 65  rly distinguishe
0ba0: 64 20 66 72 6f 6d 20 6f 72 64 69 6e 61 72 79 20  d from ordinary 
0bb0: 54 61 62 6c 65 73 2e 3c 62 72 3e 3c 62 72 3e 0d  Tables.<br><br>.
0bc0: 0a 3c 62 3e 4e 6f 74 69 63 65 3c 2f 62 3e 3a 20  .<b>Notice</b>: 
0bd0: 61 6c 6c 20 50 6f 73 74 67 72 65 73 20 54 61 62  all Postgres Tab
0be0: 6c 65 73 20 61 6e 64 20 56 69 65 77 73 20 28 6e  les and Views (n
0bf0: 61 6d 65 6c 79 3a 20 3c 62 3e 56 69 72 74 75 61  amely: <b>Virtua
0c00: 6c 50 6f 73 74 67 72 65 73 3c 2f 62 3e 20 54 61  lPostgres</b> Ta
0c10: 62 6c 65 73 29 20 77 69 6c 6c 20 61 6c 77 61 79  bles) will alway
0c20: 73 20 68 61 76 65 20 61 20 63 6f 6e 76 65 6e 74  s have a convent
0c30: 69 6f 6e 61 6c 20 6e 61 6d 65 20 73 74 61 72 74  ional name start
0c40: 69 6e 67 20 77 69 74 68 20 61 20 3c 62 3e 76 70  ing with a <b>vp
0c50: 67 5f 3c 2f 62 3e 20 70 72 65 66 69 78 2e 3c 62  g_</b> prefix.<b
0c60: 72 3e 0d 0a 57 68 65 6e 65 76 65 72 20 70 6f 73  r>..Whenever pos
0c70: 73 69 62 6c 65 20 74 68 65 20 6f 72 69 67 69 6e  sible the origin
0c80: 61 6c 20 50 6f 73 74 67 72 65 73 20 4e 61 6d 65  al Postgres Name
0c90: 20 77 69 6c 6c 20 62 65 20 70 72 65 73 65 72 76   will be preserv
0ca0: 65 64 2c 20 6f 74 68 65 72 77 69 73 65 20 69 74  ed, otherwise it
0cb0: 20 77 69 6c 6c 20 62 65 20 64 69 73 61 6d 62 69   will be disambi
0cc0: 67 75 61 74 65 64 20 62 79 20 61 64 64 69 6e 67  guated by adding
0cd0: 20 61 6e 20 61 70 70 72 6f 70 72 69 61 74 65 20   an appropriate 
0ce0: 6e 75 6d 65 72 69 63 20 73 75 66 66 69 78 2e 3c  numeric suffix.<
0cf0: 62 72 3e 3c 62 72 3e 3c 62 72 3e 0d 0a 3c 68 72  br><br><br>..<hr
0d00: 3e 0d 0a 3c 62 72 3e 3c 62 72 3e 0d 0a 3c 62 3e  >..<br><br>..<b>
0d10: 4e 6f 74 65 3c 2f 62 3e 3a 20 61 6c 6c 20 64 61  Note</b>: all da
0d20: 74 61 62 61 73 65 20 6f 62 6a 65 63 74 73 20 69  tabase objects i
0d30: 6e 20 74 68 65 20 50 6f 73 74 67 72 65 73 20 54  n the Postgres T
0d40: 72 65 65 20 61 72 65 20 69 6e 65 72 65 6e 74 6c  ree are inerentl
0d50: 79 20 74 72 61 6e 73 69 65 6e 74 2c 20 61 6e 64  y transient, and
0d60: 20 77 69 6c 6c 20 61 75 74 6f 6d 61 74 69 63 61   will automatica
0d70: 6c 6c 79 20 64 69 73 61 70 70 65 61 72 20 77 68  lly disappear wh
0d80: 65 6e 20 74 68 65 20 63 6f 72 72 65 73 70 6f 6e  en the correspon
0d90: 64 69 6e 67 20 63 6f 6e 6e 65 63 74 69 6f 6e 20  ding connection 
0da0: 77 69 6c 6c 20 62 65 20 63 6c 6f 73 65 64 2c 20  will be closed, 
0db0: 6f 72 20 77 68 65 6e 20 74 68 65 20 63 75 72 72  or when the curr
0dc0: 65 6e 74 20 73 65 73 73 69 6f 6e 20 65 6e 64 73  ent session ends
0dd0: 2e 3c 2f 74 64 3e 0d 0a 3c 74 64 3e 3c 69 6d 67  .</td>..<td><img
0de0: 20 73 72 63 3d 22 68 74 74 70 73 3a 2f 2f 77 77   src="https://ww
0df0: 77 2e 67 61 69 61 2d 67 69 73 2e 69 74 2f 67 61  w.gaia-gis.it/ga
0e00: 69 61 2d 73 69 6e 73 2f 67 75 69 2d 70 6f 73 74  ia-sins/gui-post
0e10: 67 72 65 73 2f 67 75 69 35 2e 70 6e 67 22 20 61  gres/gui5.png" a
0e20: 6c 74 3d 22 74 61 62 6c 65 20 74 72 65 65 22 3e  lt="table tree">
0e30: 3c 2f 74 64 3e 0d 0a 3c 2f 74 72 3e 0d 0a 3c 74  </td>..</tr>..<t
0e40: 72 3e 0d 0a 3c 74 64 3e 3c 62 3e 32 2e 62 3c 2f  r>..<td><b>2.b</
0e50: 62 3e 20 69 66 2c 20 66 6f 72 20 61 6e 79 20 70  b> if, for any p
0e60: 6f 73 73 69 62 6c 65 20 72 65 61 73 6f 6e 20 28  ossible reason (
0e70: 73 79 73 74 65 6d 20 63 72 61 73 68 2c 20 70 6f  system crash, po
0e80: 77 65 72 20 66 61 69 6c 75 72 65 20 61 6e 64 20  wer failure and 
0e90: 61 6c 69 6b 65 29 2c 20 74 68 65 20 63 75 72 72  alike), the curr
0ea0: 65 6e 74 20 73 65 73 73 69 6f 6e 20 77 69 6c 6c  ent session will
0eb0: 20 66 61 69 6c 20 74 6f 20 63 6f 72 72 65 63 74   fail to correct
0ec0: 6c 79 20 70 65 72 66 6f 72 6d 20 74 68 65 20 65  ly perform the e
0ed0: 78 70 65 63 74 65 64 20 66 69 6e 61 6c 20 63 6c  xpected final cl
0ee0: 65 61 6e 75 70 2c 20 79 6f 75 72 20 53 51 4c 69  eanup, your SQLi
0ef0: 74 65 20 64 61 74 61 62 61 73 65 20 77 69 6c 6c  te database will
0f00: 20 72 65 6d 61 69 6e 20 69 6e 20 61 20 64 69 72   remain in a dir
0f10: 74 79 20 61 6e 64 20 69 6e 63 6f 6e 73 69 73 74  ty and inconsist
0f20: 65 6e 74 20 73 74 61 74 65 2e 3c 62 72 3e 0d 0a  ent state.<br>..
0f30: 41 73 20 74 68 65 20 73 69 64 65 20 66 69 67 75  As the side figu
0f40: 72 65 20 73 68 6f 77 73 2c 20 77 68 65 6e 20 72  re shows, when r
0f50: 65 73 74 61 72 74 69 6e 67 20 61 20 6e 65 77 20  estarting a new 
0f60: 73 65 73 73 69 6f 6e 20 6d 61 6e 79 20 3c 62 3e  session many <b>
0f70: 3c 69 3e 6f 72 70 68 61 6e 20 56 69 72 74 75 61  <i>orphan Virtua
0f80: 6c 50 6f 73 74 67 72 65 73 20 74 61 62 6c 65 73  lPostgres tables
0f90: 3c 2f 69 3e 3c 2f 62 3e 20 77 69 6c 6c 20 62 61  </i></b> will ba
0fa0: 64 6c 79 20 72 65 6d 61 69 6e 20 66 72 6f 6d 20  dly remain from 
0fb0: 74 68 65 20 6c 61 73 74 20 61 62 6f 72 74 65 64  the last aborted
0fc0: 20 73 65 73 73 69 6f 6e 2e 3c 62 72 3e 3c 62 72   session.<br><br
0fd0: 3e 0d 0a 49 66 20 74 68 69 73 20 69 73 20 79 6f  >..If this is yo
0fe0: 75 72 20 63 61 73 65 2c 20 64 6f 6e 27 74 20 64  ur case, don't d
0ff0: 65 73 70 61 69 72 3a 20 79 6f 75 20 6a 75 73 74  espair: you just
1000: 20 68 61 76 65 20 74 6f 20 73 65 6c 65 63 74 20   have to select 
1010: 74 68 65 20 61 70 70 72 6f 70 72 69 61 74 65 20  the appropriate 
1020: 69 74 65 6d 20 66 72 6f 6d 20 74 68 65 20 50 6f  item from the Po
1030: 73 74 67 72 65 73 20 63 6f 6e 74 61 78 74 20 6d  stgres contaxt m
1040: 65 6e 75 20 61 6e 64 20 74 68 65 20 44 42 20 77  enu and the DB w
1050: 69 6c 6c 20 62 65 20 69 6d 6d 65 64 69 61 74 65  ill be immediate
1060: 6c 79 20 72 65 63 6f 76 65 72 65 64 20 69 6e 20  ly recovered in 
1070: 61 20 73 61 66 65 20 63 6f 6e 73 69 73 74 65 6e  a safe consisten
1080: 74 20 61 6e 64 20 63 6c 65 61 6e 20 73 74 61 74  t and clean stat
1090: 65 2e 3c 2f 74 64 3e 0d 0a 3c 74 64 3e 3c 69 6d  e.</td>..<td><im
10a0: 67 20 73 72 63 3d 22 68 74 74 70 73 3a 2f 2f 77  g src="https://w
10b0: 77 77 2e 67 61 69 61 2d 67 69 73 2e 69 74 2f 67  ww.gaia-gis.it/g
10c0: 61 69 61 2d 73 69 6e 73 2f 67 75 69 2d 70 6f 73  aia-sins/gui-pos
10d0: 74 67 72 65 73 2f 6f 72 70 68 61 6e 73 2e 70 6e  tgres/orphans.pn
10e0: 67 22 20 61 6c 74 3d 22 6f 72 70 68 61 6e 20 74  g" alt="orphan t
10f0: 61 62 6c 65 73 22 3e 3c 2f 74 64 3e 0d 0a 3c 2f  ables"></td>..</
1100: 74 72 3e 0d 0a 3c 74 72 3e 3c 74 64 20 63 6f 6c  tr>..<tr><td col
1110: 73 70 61 6e 3d 22 33 22 20 61 6c 69 67 6e 3d 22  span="3" align="
1120: 63 65 6e 74 65 72 22 3e 3c 68 33 3e 33 20 2d 20  center"><h3>3 - 
1130: 4d 65 74 61 64 61 74 61 20 6f 66 20 50 6f 73 74  Metadata of Post
1140: 67 72 65 53 51 4c 20 6f 62 6a 65 63 74 73 3c 2f  greSQL objects</
1150: 68 33 3e 3c 68 72 3e 3c 2f 74 64 3e 3c 2f 74 72  h3><hr></td></tr
1160: 3e 0d 0a 3c 74 72 3e 0d 0a 3c 74 64 3e 3c 62 3e  >..<tr>..<td><b>
1170: 33 2e 61 3c 2f 62 3e 20 79 6f 75 20 63 61 6e 20  3.a</b> you can 
1180: 65 61 73 69 6c 79 20 71 75 65 72 79 20 74 68 65  easily query the
1190: 20 6d 65 74 61 64 61 74 61 20 66 6f 72 20 65 61   metadata for ea
11a0: 63 68 20 50 6f 73 74 67 72 65 73 20 6f 62 6a 65  ch Postgres obje
11b0: 63 74 3b 20 6a 75 73 74 20 73 65 6c 65 63 74 20  ct; just select 
11c0: 74 68 65 20 61 70 70 72 6f 70 72 69 61 74 65 20  the appropriate 
11d0: 69 74 65 6d 20 66 72 6f 6d 20 74 68 65 20 63 6f  item from the co
11e0: 6e 74 65 78 74 20 6d 65 6e 75 2e 3c 2f 74 64 3e  ntext menu.</td>
11f0: 0d 0a 3c 74 64 3e 3c 69 6d 67 20 73 72 63 3d 22  ..<td><img src="
1200: 68 74 74 70 73 3a 2f 2f 77 77 77 2e 67 61 69 61  https://www.gaia
1210: 2d 67 69 73 2e 69 74 2f 67 61 69 61 2d 73 69 6e  -gis.it/gaia-sin
1220: 73 2f 67 75 69 2d 70 6f 73 74 67 72 65 73 2f 67  s/gui-postgres/g
1230: 75 69 36 2e 70 6e 67 22 20 61 6c 74 3d 22 6d 65  ui6.png" alt="me
1240: 74 61 64 61 74 61 20 69 6e 66 6f 22 3e 3c 2f 74  tadata info"></t
1250: 64 3e 0d 0a 3c 2f 74 72 3e 0d 0a 3c 74 72 3e 0d  d>..</tr>..<tr>.
1260: 0a 3c 74 64 3e 3c 62 3e 33 2e 62 3c 2f 62 3e 20  .<td><b>3.b</b> 
1270: 4d 65 74 61 64 61 74 61 20 66 6f 72 20 61 20 3c  Metadata for a <
1280: 62 3e 43 6f 6e 6e 65 63 74 69 6f 6e 3c 2f 62 3e  b>Connection</b>
1290: 20 3c 69 3e 61 6b 61 3c 2f 69 3e 20 3c 62 3e 44   <i>aka</i> <b>D
12a0: 61 74 61 62 61 73 65 3c 2f 62 3e 20 6f 62 6a 65  atabase</b> obje
12b0: 63 74 20 77 69 6c 6c 20 72 65 70 6f 72 74 20 74  ct will report t
12c0: 68 65 20 69 6e 69 74 69 61 6c 20 63 6f 6e 6e 65  he initial conne
12d0: 63 74 69 6f 6e 20 61 72 67 75 6d 65 6e 74 73 2e  ction arguments.
12e0: 3c 62 72 3e 3c 62 72 3e 3c 62 72 3e 0d 0a 3c 68  <br><br><br>..<h
12f0: 72 3e 0d 0a 3c 62 72 3e 3c 62 72 3e 0d 0a 3c 62  r>..<br><br>..<b
1300: 3e 4e 6f 74 65 3c 2f 62 3e 3a 20 79 6f 75 20 63  >Note</b>: you c
1310: 61 6e 20 65 76 65 6e 74 75 61 6c 6c 79 20 63 6f  an eventually co
1320: 6e 6e 65 63 74 20 6d 6f 72 65 20 74 68 61 6e 20  nnect more than 
1330: 61 20 73 69 6e 67 6c 65 20 50 6f 73 74 67 72 65  a single Postgre
1340: 73 20 44 61 74 61 62 61 73 65 20 69 6e 20 74 68  s Database in th
1350: 65 20 73 61 6d 65 20 73 65 73 73 6f 6e 3a 20 63  e same sesson: c
1360: 6f 6e 6e 65 63 74 69 6e 67 20 74 77 69 63 65 20  onnecting twice 
1370: 74 68 65 20 73 61 6d 65 20 44 61 74 61 62 61 73  the same Databas
1380: 65 20 69 73 20 61 6c 6c 77 61 79 73 20 66 6f 72  e is allways for
1390: 62 69 64 64 65 6e 2e 3c 2f 74 64 3e 0d 0a 3c 74  bidden.</td>..<t
13a0: 64 3e 3c 69 6d 67 20 73 72 63 3d 22 68 74 74 70  d><img src="http
13b0: 73 3a 2f 2f 77 77 77 2e 67 61 69 61 2d 67 69 73  s://www.gaia-gis
13c0: 2e 69 74 2f 67 61 69 61 2d 73 69 6e 73 2f 67 75  .it/gaia-sins/gu
13d0: 69 2d 70 6f 73 74 67 72 65 73 2f 67 75 69 37 2e  i-postgres/gui7.
13e0: 70 6e 67 22 20 61 6c 74 3d 22 63 6f 6e 6e 65 63  png" alt="connec
13f0: 74 69 6f 6e 20 6d 65 74 61 64 61 74 61 22 3e 3c  tion metadata"><
1400: 2f 74 64 3e 0d 0a 3c 2f 74 72 3e 0d 0a 3c 74 72  /td>..</tr>..<tr
1410: 3e 0d 0a 3c 74 64 3e 3c 62 3e 33 2e 63 3c 2f 62  >..<td><b>3.c</b
1420: 3e 20 4d 65 74 61 64 61 74 61 20 66 6f 72 20 61  > Metadata for a
1430: 20 3c 62 3e 53 63 68 65 6d 61 3c 2f 62 3e 20 6f   <b>Schema</b> o
1440: 62 6a 65 63 74 20 61 72 65 6e 27 74 20 72 65 61  bject aren't rea
1450: 6c 6c 79 20 69 6e 74 65 72 65 73 74 69 6e 67 2c  lly interesting,
1460: 20 62 65 63 61 75 73 65 20 6a 75 73 74 20 74 68   because just th
1470: 65 20 6e 61 6d 65 20 69 73 20 72 65 70 6f 72 74  e name is report
1480: 65 64 2e 3c 2f 74 64 3e 0d 0a 3c 74 64 3e 3c 69  ed.</td>..<td><i
1490: 6d 67 20 73 72 63 3d 22 68 74 74 70 73 3a 2f 2f  mg src="https://
14a0: 77 77 77 2e 67 61 69 61 2d 67 69 73 2e 69 74 2f  www.gaia-gis.it/
14b0: 67 61 69 61 2d 73 69 6e 73 2f 67 75 69 2d 70 6f  gaia-sins/gui-po
14c0: 73 74 67 72 65 73 2f 67 75 69 38 2e 70 6e 67 22  stgres/gui8.png"
14d0: 20 61 6c 74 3d 22 73 63 68 65 6d 61 20 6d 65 74   alt="schema met
14e0: 61 64 61 74 61 22 3e 3c 2f 74 64 3e 0d 0a 3c 2f  adata"></td>..</
14f0: 74 72 3e 0d 0a 3c 74 72 3e 0d 0a 3c 74 64 3e 3c  tr>..<tr>..<td><
1500: 62 3e 33 2e 64 3c 2f 62 3e 20 4d 65 74 61 64 61  b>3.d</b> Metada
1510: 74 61 20 66 6f 72 20 3c 62 3e 54 61 62 6c 65 3c  ta for <b>Table<
1520: 2f 62 3e 20 6f 72 20 3c 62 3e 56 69 65 77 3c 2f  /b> or <b>View</
1530: 62 3e 20 6f 62 6a 65 63 74 73 20 77 69 6c 6c 20  b> objects will 
1540: 72 65 70 6f 72 74 20 61 6c 6c 20 3c 62 3e 47 52  report all <b>GR
1550: 41 4e 54 20 70 65 72 6d 69 73 73 69 6f 6e 73 3c  ANT permissions<
1560: 2f 62 3e 20 66 6f 72 20 74 68 65 20 63 75 72 72  /b> for the curr
1570: 65 6e 74 20 55 73 65 72 2e 3c 62 72 3e 3c 62 72  ent User.<br><br
1580: 3e 3c 62 72 3e 0d 0a 3c 68 72 3e 0d 0a 3c 62 72  ><br>..<hr>..<br
1590: 3e 3c 62 72 3e 0d 0a 3c 62 3e 4e 6f 74 65 3c 2f  ><br>..<b>Note</
15a0: 62 3e 3a 20 61 6c 73 6f 20 69 6e 20 74 68 65 20  b>: also in the 
15b0: 63 61 73 65 20 6f 66 20 61 20 3c 62 3e 52 45 41  case of a <b>REA
15c0: 44 2d 57 52 49 54 45 3c 2f 62 3e 20 65 6e 61 62  D-WRITE</b> enab
15d0: 6c 65 64 20 63 6f 6e 6e 65 63 74 69 6f 6e 2c 20  led connection, 
15e0: 61 6c 6c 20 50 6f 73 74 67 72 65 73 20 54 61 62  all Postgres Tab
15f0: 6c 65 73 20 6c 61 63 6b 69 6e 67 20 74 68 65 20  les lacking the 
1600: 70 65 72 6d 69 73 73 69 6f 6e 20 74 6f 20 65 78  permission to ex
1610: 65 63 75 74 65 20 3c 62 3e 49 4e 53 45 52 54 3c  ecute <b>INSERT<
1620: 2f 62 3e 2c 20 3c 62 3e 55 50 44 41 54 45 3c 2f  /b>, <b>UPDATE</
1630: 62 3e 20 6f 72 20 3c 62 3e 44 45 4c 45 54 45 3c  b> or <b>DELETE<
1640: 2f 62 3e 20 73 74 61 74 65 6d 65 6e 74 73 20 77  /b> statements w
1650: 69 6c 6c 20 62 65 20 61 6c 6c 77 61 79 73 20 63  ill be allways c
1660: 6f 6e 73 69 64 65 72 65 64 20 74 6f 20 62 65 20  onsidered to be 
1670: 3c 62 3e 52 45 41 44 2d 4f 4e 4c 59 3c 2f 62 3e  <b>READ-ONLY</b>
1680: 2e 3c 62 72 3e 0d 0a 45 78 61 63 74 6c 79 20 61  .<br>..Exactly a
1690: 73 20 61 6e 79 20 6f 74 68 65 72 20 54 61 62 6c  s any other Tabl
16a0: 65 20 6e 6f 74 20 73 75 70 70 6f 72 74 65 64 20  e not supported 
16b0: 62 79 20 61 20 3c 62 3e 50 52 49 4d 41 52 59 20  by a <b>PRIMARY 
16c0: 4b 45 59 3c 2f 62 3e 20 64 65 66 69 6e 69 74 69  KEY</b> definiti
16d0: 6f 6e 2e 3c 2f 74 64 3e 0d 0a 3c 74 64 3e 3c 69  on.</td>..<td><i
16e0: 6d 67 20 73 72 63 3d 22 68 74 74 70 73 3a 2f 2f  mg src="https://
16f0: 77 77 77 2e 67 61 69 61 2d 67 69 73 2e 69 74 2f  www.gaia-gis.it/
1700: 67 61 69 61 2d 73 69 6e 73 2f 67 75 69 2d 70 6f  gaia-sins/gui-po
1710: 73 74 67 72 65 73 2f 67 75 69 39 2e 70 6e 67 22  stgres/gui9.png"
1720: 20 61 6c 74 3d 22 74 61 62 6c 65 20 6d 65 74 61   alt="table meta
1730: 64 61 74 61 22 3e 3c 2f 74 64 3e 0d 0a 3c 2f 74  data"></td>..</t
1740: 72 3e 0d 0a 3c 74 72 3e 0d 0a 3c 74 64 3e 3c 62  r>..<tr>..<td><b
1750: 3e 33 2e 65 3c 2f 62 3e 20 4d 65 74 61 64 61 74  >3.e</b> Metadat
1760: 61 20 66 6f 72 20 61 20 3c 62 3e 50 6f 73 74 47  a for a <b>PostG
1770: 49 53 20 54 61 62 6c 65 3c 2f 62 3e 20 6f 62 6a  IS Table</b> obj
1780: 65 63 74 73 20 77 69 6c 6c 20 72 65 70 6f 72 74  ects will report
1790: 20 61 20 66 75 6c 6c 20 71 75 61 6c 69 66 69 63   a full qualific
17a0: 61 74 69 6f 6e 20 6f 66 20 74 68 65 20 3c 62 3e  ation of the <b>
17b0: 47 45 4f 4d 45 54 52 59 3c 2f 62 3e 20 63 6f 6c  GEOMETRY</b> col
17c0: 75 6d 6e 28 73 29 2c 20 74 68 69 73 20 69 6e 63  umn(s), this inc
17d0: 6c 75 64 69 6e 67 20 74 68 65 20 47 65 6f 6d 65  luding the Geome
17e0: 74 72 79 54 79 70 65 2c 20 74 68 65 20 53 72 69  tryType, the Sri
17f0: 64 20 61 6e 64 20 74 68 65 20 43 6f 6f 72 64 69  d and the Coordi
1800: 6e 61 74 65 44 69 6d 65 6e 73 69 6f 6e 73 2e 3c  nateDimensions.<
1810: 2f 74 64 3e 0d 0a 3c 74 64 3e 3c 69 6d 67 20 73  /td>..<td><img s
1820: 72 63 3d 22 68 74 74 70 73 3a 2f 2f 77 77 77 2e  rc="https://www.
1830: 67 61 69 61 2d 67 69 73 2e 69 74 2f 67 61 69 61  gaia-gis.it/gaia
1840: 2d 73 69 6e 73 2f 67 75 69 2d 70 6f 73 74 67 72  -sins/gui-postgr
1850: 65 73 2f 67 75 69 31 30 2e 70 6e 67 22 20 61 6c  es/gui10.png" al
1860: 74 3d 22 70 6f 73 74 67 69 73 20 6d 65 74 61 64  t="postgis metad
1870: 61 74 61 22 3e 3c 2f 74 64 3e 0d 0a 3c 2f 74 72  ata"></td>..</tr
1880: 3e 0d 0a 3c 74 72 3e 0d 0a 3c 74 64 3e 3c 62 3e  >..<tr>..<td><b>
1890: 33 2e 66 3c 2f 62 3e 20 61 6c 6c 20 3c 62 3e 50  3.f</b> all <b>P
18a0: 6f 73 74 47 49 53 20 54 61 62 6c 65 73 3c 2f 62  ostGIS Tables</b
18b0: 3e 20 77 69 6c 6c 20 61 6c 77 61 79 73 20 68 61  > will always ha
18c0: 76 65 20 61 20 3c 62 3e 63 6f 6d 70 61 6e 69 6f  ve a <b>companio
18d0: 6e 20 54 61 62 6c 65 3c 2f 62 3e 20 73 68 61 72  n Table</b> shar
18e0: 69 6e 67 20 74 68 65 20 73 61 6d 65 20 69 64 65  ing the same ide
18f0: 6e 74 69 63 61 6c 20 6e 61 6d 65 20 65 78 63 65  ntical name exce
1900: 70 74 20 74 68 61 74 20 66 6f 72 20 61 20 66 69  pt that for a fi
1910: 6e 61 6c 20 3c 62 3e 5f 70 6f 73 74 67 69 73 3c  nal <b>_postgis<
1920: 2f 62 3e 20 73 75 66 66 69 78 2e 3c 62 72 3e 3c  /b> suffix.<br><
1930: 62 72 3e 3c 62 72 3e 0d 0a 3c 62 3e 4e 6f 74 65  br><br>..<b>Note
1940: 3c 2f 62 3e 3a 20 74 68 65 73 65 20 61 72 65 20  </b>: these are 
1950: 6e 6f 74 20 3c 62 3e 56 69 72 74 75 61 6c 50 6f  not <b>VirtualPo
1960: 73 74 67 72 65 73 20 54 61 62 6c 65 73 3c 2f 62  stgres Tables</b
1970: 3e 3b 20 74 68 65 79 20 61 72 65 20 69 6e 73 74  >; they are inst
1980: 65 61 64 20 53 70 61 74 69 61 6c 69 74 65 27 73  ead Spatialite's
1990: 20 6f 77 6e 20 3c 62 3e 53 70 61 74 69 61 6c 20   own <b>Spatial 
19a0: 56 69 65 77 73 3c 2f 62 3e 2c 20 61 6e 64 20 74  Views</b>, and t
19b0: 68 65 69 72 20 69 6e 74 65 6e 64 65 64 20 73 63  heir intended sc
19c0: 6f 70 65 20 69 73 20 74 6f 20 70 65 72 66 6f 72  ope is to perfor
19d0: 6d 20 61 20 73 69 6c 65 6e 74 20 61 6e 64 20 66  m a silent and f
19e0: 75 6c 6c 79 20 74 72 61 6e 73 70 61 72 65 6e 74  ully transparent
19f0: 20 63 6f 6e 76 65 72 73 69 6f 6e 20 6f 66 20 62   conversion of b
1a00: 69 6e 61 72 79 20 47 65 6f 6d 65 74 72 69 65 73  inary Geometries
1a10: 20 6e 61 63 6b 20 61 6e 64 20 66 6f 72 74 68 20   nack and forth 
1a20: 66 72 6f 6d 20 6f 6e 65 20 66 6f 72 6d 61 74 20  from one format 
1a30: 74 6f 20 74 68 65 20 6f 74 68 65 72 20 69 6e 20  to the other in 
1a40: 74 68 65 20 6d 6f 73 74 20 75 73 65 72 20 66 72  the most user fr
1a50: 69 65 6e 64 6c 79 20 77 61 79 2e 3c 2f 74 64 3e  iendly way.</td>
1a60: 0d 0a 3c 74 64 3e 3c 69 6d 67 20 73 72 63 3d 22  ..<td><img src="
1a70: 68 74 74 70 73 3a 2f 2f 77 77 77 2e 67 61 69 61  https://www.gaia
1a80: 2d 67 69 73 2e 69 74 2f 67 61 69 61 2d 73 69 6e  -gis.it/gaia-sin
1a90: 73 2f 67 75 69 2d 70 6f 73 74 67 72 65 73 2f 67  s/gui-postgres/g
1aa0: 75 69 31 31 2e 70 6e 67 22 20 61 6c 74 3d 22 70  ui11.png" alt="p
1ab0: 6f 73 74 67 69 73 20 77 72 61 70 70 65 72 20 6d  ostgis wrapper m
1ac0: 65 74 61 64 61 74 61 22 3e 3c 2f 74 64 3e 0d 0a  etadata"></td>..
1ad0: 3c 2f 74 72 3e 0d 0a 3c 74 72 3e 3c 74 64 20 63  </tr>..<tr><td c
1ae0: 6f 6c 73 70 61 6e 3d 22 33 22 20 61 6c 69 67 6e  olspan="3" align
1af0: 3d 22 63 65 6e 74 65 72 22 3e 3c 68 33 3e 34 20  ="center"><h3>4 
1b00: 2d 20 48 61 6e 64 6c 69 6e 67 20 50 6f 73 74 67  - Handling Postg
1b10: 72 65 53 51 4c 20 54 61 62 6c 65 73 20 61 6e 64  reSQL Tables and
1b20: 20 56 69 65 77 73 3c 2f 68 33 3e 3c 68 72 3e 3c   Views</h3><hr><
1b30: 2f 74 64 3e 3c 2f 74 72 3e 0d 0a 3c 74 72 3e 0d  /td></tr>..<tr>.
1b40: 0a 3c 74 64 3e 3c 62 3e 34 2e 61 3c 2f 62 3e 20  .<td><b>4.a</b> 
1b50: 50 6f 73 74 67 72 65 53 51 4c 20 54 61 62 6c 65  PostgreSQL Table
1b60: 73 20 61 6e 64 20 56 69 65 77 73 20 61 72 65 20  s and Views are 
1b70: 63 6f 6e 73 69 64 65 72 65 64 2c 20 61 73 20 66  considered, as f
1b80: 61 72 20 61 73 20 70 6f 73 73 69 62 6c 65 2c 20  ar as possible, 
1b90: 61 73 20 69 66 20 74 68 65 79 20 77 65 72 65 20  as if they were 
1ba0: 6e 61 74 69 76 65 20 53 51 4c 69 74 65 20 6f 62  native SQLite ob
1bb0: 6a 65 63 74 73 2e 3c 62 72 3e 0d 0a 53 6f 20 74  jects.<br>..So t
1bc0: 68 65 20 75 73 75 61 6c 20 6f 70 65 72 61 74 69  he usual operati
1bd0: 6f 6e 73 20 73 75 70 70 6f 72 74 65 64 20 6f 6e  ons supported on
1be0: 20 53 51 4c 69 74 65 27 73 20 6f 77 6e 20 6f 62   SQLite's own ob
1bf0: 6a 65 63 74 73 20 77 69 6c 6c 20 62 65 20 73 75  jects will be su
1c00: 70 70 6f 72 74 65 64 20 61 6c 73 6f 20 69 6e 20  pported also in 
1c10: 74 68 65 20 63 61 73 65 20 6f 66 20 50 6f 73 74  the case of Post
1c20: 67 72 65 53 51 4c 20 6f 62 6a 65 63 74 73 2e 3c  greSQL objects.<
1c30: 2f 74 64 3e 0d 0a 3c 74 64 3e 3c 69 6d 67 20 73  /td>..<td><img s
1c40: 72 63 3d 22 68 74 74 70 73 3a 2f 2f 77 77 77 2e  rc="https://www.
1c50: 67 61 69 61 2d 67 69 73 2e 69 74 2f 67 61 69 61  gaia-gis.it/gaia
1c60: 2d 73 69 6e 73 2f 67 75 69 2d 70 6f 73 74 67 72  -sins/gui-postgr
1c70: 65 73 2f 67 75 69 31 32 2e 70 6e 67 22 20 61 6c  es/gui12.png" al
1c80: 74 3d 22 74 61 62 6c 65 20 6f 70 65 72 61 74 69  t="table operati
1c90: 6f 6e 73 22 3e 3c 2f 74 64 3e 0d 0a 3c 2f 74 72  ons"></td>..</tr
1ca0: 3e 0d 0a 3c 74 72 3e 0d 0a 3c 74 64 3e 3c 62 3e  >..<tr>..<td><b>
1cb0: 34 2e 62 3c 2f 62 3e 20 74 68 65 20 61 62 6f 76  4.b</b> the abov
1cc0: 65 20 63 72 69 74 65 72 69 61 20 77 69 6c 6c 20  e criteria will 
1cd0: 61 70 70 6c 79 20 61 6c 73 6f 20 74 6f 20 50 6f  apply also to Po
1ce0: 73 74 47 49 53 20 47 65 6f 6d 65 74 72 69 65 73  stGIS Geometries
1cf0: 2e 3c 62 72 3e 3c 62 72 3e 3c 62 72 3e 0d 0a 3c  .<br><br><br>..<
1d00: 62 3e 48 69 6e 74 3c 2f 62 3e 3a 20 65 78 70 6f  b>Hint</b>: expo
1d10: 72 74 69 6e 67 20 61 20 66 75 6c 6c 20 53 68 61  rting a full Sha
1d20: 70 65 66 69 6c 65 20 66 72 6f 6d 20 61 20 50 6f  pefile from a Po
1d30: 73 74 47 49 53 20 47 65 6f 6d 65 74 72 79 20 77  stGIS Geometry w
1d40: 61 73 20 6e 65 76 65 72 20 6d 6f 72 65 20 64 69  as never more di
1d50: 72 65 63 74 20 61 6e 64 20 73 69 6d 70 6c 65 20  rect and simple 
1d60: 74 68 61 6e 20 74 68 69 73 2e 3c 2f 74 64 3e 0d  than this.</td>.
1d70: 0a 3c 74 64 3e 3c 69 6d 67 20 73 72 63 3d 22 68  .<td><img src="h
1d80: 74 74 70 73 3a 2f 2f 77 77 77 2e 67 61 69 61 2d  ttps://www.gaia-
1d90: 67 69 73 2e 69 74 2f 67 61 69 61 2d 73 69 6e 73  gis.it/gaia-sins
1da0: 2f 67 75 69 2d 70 6f 73 74 67 72 65 73 2f 67 75  /gui-postgres/gu
1db0: 69 31 33 2e 70 6e 67 22 20 61 6c 74 3d 22 67 65  i13.png" alt="ge
1dc0: 6f 6d 65 74 72 79 20 6f 70 65 72 61 74 69 6f 6e  ometry operation
1dd0: 73 22 3e 3c 2f 74 64 3e 0d 0a 3c 2f 74 72 3e 0d  s"></td>..</tr>.
1de0: 0a 3c 2f 74 61 62 6c 65 3e 0d 0a 0d 0a 0d 0a 42  .</table>......B
1df0: 61 63 6b 20 74 6f 20 3c 61 20 68 72 65 66 3d 22  ack to <a href="
1e00: 68 74 74 70 73 3a 2f 2f 77 77 77 2e 67 61 69 61  https://www.gaia
1e10: 2d 67 69 73 2e 69 74 2f 66 6f 73 73 69 6c 2f 73  -gis.it/fossil/s
1e20: 70 61 74 69 61 6c 69 74 65 5f 67 75 69 2f 77 69  patialite_gui/wi
1e30: 6b 69 3f 6e 61 6d 65 3d 73 70 61 74 69 61 6c 69  ki?name=spatiali
1e40: 74 65 2d 67 75 69 22 3e 6d 61 69 6e 20 57 69 6b  te-gui">main Wik
1e50: 69 20 70 61 67 65 3c 2f 61 3e 0a 5a 20 36 37 39  i page</a>.Z 679
1e60: 38 31 66 34 31 38 37 33 30 30 35 33 30 30 34 30  81f4187300530040
1e70: 62 66 31 63 64 66 65 37 35 31 38 38 30 0a        bf1cdfe751880.